test units
[time-w3c.git] / Setup.hs
index cd7dc32771c50dfce0f84edbdd953488e9dd68cd..60a326f276468501a09b8a484bb4c5cdda91b06a 100644 (file)
--- a/Setup.hs
+++ b/Setup.hs
@@ -1,3 +1,9 @@
 #!/usr/bin/env runhaskell
 import Distribution.Simple
-main = defaultMain
+import System.Cmd
+import System.Exit
+
+main = defaultMainWithHooks (simpleUserHooks { runTests = runTestUnit })
+    where
+      runTestUnit _ _ _ _
+          = system "./dist/build/W3CDateTimeUnitTest/W3CDateTimeUnitTest" >> return ()