X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=src%2FCardinal.hs;h=d4f94e3c55e530de9008e7fbc276c9a4062f332b;hb=a499efdb0e215ac424fe7c38a52430daebefc22b;hp=ff410a8769fa304f935984e9f5a6fccabb1e9272;hpb=957754c693525096c5fd7427decd6404bbb03379;p=spline3.git diff --git a/src/Cardinal.hs b/src/Cardinal.hs index ff410a8..d4f94e3 100644 --- a/src/Cardinal.hs +++ b/src/Cardinal.hs @@ -9,18 +9,28 @@ -- center of a cube. In addition to those 26 directions, we also -- include the interior point and a number of composite types that -- allow us to perform arithmetic on directions. -module Cardinal +-- +module Cardinal ( + Cardinal(..), + cardinal_properties, + cardinal_tests, + ccwx, + ccwy, + ccwz, + cwx, + cwy, + cwz ) where import Control.Monad (liftM, liftM2) import Prelude hiding (LT) - -import Test.HUnit -import Test.Framework (Test, testGroup) -import Test.Framework.Providers.HUnit (testCase) -import Test.Framework.Providers.QuickCheck2 (testProperty) - -import Test.QuickCheck (Arbitrary(..), Property, (==>), oneof) +import Test.Tasty ( TestTree, testGroup ) +import Test.Tasty.HUnit ( Assertion, assertEqual, testCase ) +import Test.Tasty.QuickCheck ( + Arbitrary(..), + Property, (==>), + oneof, + testProperty ) data Cardinal = F -- ^ Front @@ -430,17 +440,17 @@ prop_four_ccwz_is_identity c = (ccwz . ccwz . ccwz . ccwz) c == c -cardinal_tests :: Test.Framework.Test +cardinal_tests :: TestTree cardinal_tests = - testGroup "Cardinal Tests" [ + testGroup "Cardinal tests" [ testCase "c-tilde_2100 rotation correct"test_c_tilde_2100_rotation_correct ] -cardinal_properties :: Test.Framework.Test +cardinal_properties :: TestTree cardinal_properties = let tp = testProperty in - testGroup "Cardinal Properties" [ + testGroup "Cardinal properties" [ tp "ccwx rotation changes direction" prop_ccwx_rotation_changes_direction, tp "cwx rotation changes direction" prop_cwx_rotation_changes_direction, tp "ccwy rotation changes direction" prop_ccwy_rotation_changes_direction,