diff options
author | Péter Diviánszky <divipp@gmail.com> | 2016-01-25 14:41:00 +0100 |
---|---|---|
committer | Péter Diviánszky <divipp@gmail.com> | 2016-01-25 14:41:05 +0100 |
commit | b7483fb783243658ad50b7442be23227d14c5368 (patch) | |
tree | aa053e61b09527975681c52394ef125dbf22cbf2 /test/runTests.hs | |
parent | a10900b1e1ba329d81ec8fff1e51f1d64156b981 (diff) |
small refactoring
Diffstat (limited to 'test/runTests.hs')
-rw-r--r-- | test/runTests.hs | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/test/runTests.hs b/test/runTests.hs index a8bc4a8b..4e27cf79 100644 --- a/test/runTests.hs +++ b/test/runTests.hs | |||
@@ -83,13 +83,6 @@ instance NFData TestCaseTag where | |||
83 | 83 | ||
84 | type TestCasePath = TestCase FilePath | 84 | type TestCasePath = TestCase FilePath |
85 | 85 | ||
86 | isNormalTC :: TestCase a -> Bool | ||
87 | isNormalTC = (== Normal) . fst . fst | ||
88 | |||
89 | -- Is TestCase is work in progress? | ||
90 | isWipTC :: TestCase a -> Bool | ||
91 | isWipTC = (== WorkInProgress) . fst . fst | ||
92 | |||
93 | takeExtensions' :: FilePath -> [String] | 86 | takeExtensions' :: FilePath -> [String] |
94 | takeExtensions' fn = case splitExtension fn of | 87 | takeExtensions' fn = case splitExtension fn of |
95 | (_, "") -> [] | 88 | (_, "") -> [] |
@@ -139,7 +132,7 @@ main = do | |||
139 | , ["Overall time: " ++ showTime (sum $ map (fst . snd) resultDiffs)] | 132 | , ["Overall time: " ++ showTime (sum $ map (fst . snd) resultDiffs)] |
140 | ] | 133 | ] |
141 | 134 | ||
142 | when (any erroneous (map (fst . snd . testCaseVal) $ filter isNormalTC resultDiffs)) | 135 | when (any erroneous (map (fst . snd . testCaseVal) $ filter ((== Normal) . fst . fst) resultDiffs)) |
143 | exitFailure | 136 | exitFailure |
144 | putStrLn "All OK" | 137 | putStrLn "All OK" |
145 | unless (null resultDiffs) $ putStrLn "Only work in progress test cases are failing." | 138 | unless (null resultDiffs) $ putStrLn "Only work in progress test cases are failing." |