aboutsummaryrefslogtreecommitdiffstats
path: root/tests/Test.hs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/Test.hs')
-rw-r--r--tests/Test.hs19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/Test.hs b/tests/Test.hs
new file mode 100644
index 0000000..b1958c3
--- /dev/null
+++ b/tests/Test.hs
@@ -0,0 +1,19 @@
+module Main where
+
+import Test.Tasty
+import Test.Tasty.HUnit
+import Test.Tasty.QuickCheck as QC
+
+unitTests = testGroup "Unit tests"
+ [ testCase "List comparison (different length)" $
+ [1, 2, 3] `compare` [1,2] @?= GT
+
+ -- the following test does not hold
+ , testCase "List comparison (same length)" $
+ [1, 2, 3] `compare` [1,2,2] @?= LT
+ ]
+
+tests :: TestTree
+tests = testGroup "Tests" [unitTests]
+
+main = defaultMain tests