summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2015-06-29 21:31:10 +0200
committerLars-Dominik Braun <lars@6xq.net>2015-06-29 21:31:10 +0200
commit1a6457a84fb3430dbbe0270ce60e8c325906ce74 (patch)
treeb8bab05bd68f167605f24cf1030a5c3fcdc1a786 /src
parent4c6c1bcf877017df98d4a5492a665eca12b8ba98 (diff)
downloadpesto-1a6457a84fb3430dbbe0270ce60e8c325906ce74.tar.gz
pesto-1a6457a84fb3430dbbe0270ce60e8c325906ce74.tar.bz2
pesto-1a6457a84fb3430dbbe0270ce60e8c325906ce74.zip
Use cabal’s testsuite interface
Diffstat (limited to 'src')
-rw-r--r--src/Test.lhs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Test.lhs b/src/Test.lhs
index 852c700..68f1831 100644
--- a/src/Test.lhs
+++ b/src/Test.lhs
@@ -4,6 +4,7 @@ Running tests
.. class:: nodoc
> import Test.HUnit
+> import System.Exit (exitFailure, exitSuccess)
> import Codec.Pesto.Parse (test)
> import Codec.Pesto.Lint (test)
> import Codec.Pesto.Graph (test)
@@ -11,7 +12,7 @@ Running tests
The testcases can be run with ``cabal run pesto-test``. This runs *all*
testcases from all modules and prints a summary.
-> main = runTestTT tests
+> main = runTestTT tests >>= \c -> if errors c + failures c > 0 then exitFailure else exitSuccess
> tests = TestList [
> "parse" ~: Codec.Pesto.Parse.test