Debian Codegraph @

tests/runtests.agda

raw
1 {-# OPTIONS --guardedness #-}
2
3 module runtests where
4
5 open import Data.List.Base as List using (_∷_; [])
6 open import Data.String.Base using (String; _++_)
7 open import IO.Base
8 open import Function.Base
9 open import Test.Golden
10
11 dataTests : TestPool
12 dataTests = mkTestPool "Data structures"
13 $ "appending"
14 ∷ "colist"
15 ∷ "list"
16 ∷ "rational"
17 ∷ "rational-unnormalised"
18 ∷ "trie"
19 ∷ "bytestring"
20 ∷ []
21
22 systemTests : TestPool
23 systemTests = mkTestPool "System modules"
24 $ "ansi"
25 ∷ "directory"
26 ∷ "environment"
27 ∷ "io"
28 ∷ "random"
29 ∷ []
30
31 showTests : TestPool
32 showTests = mkTestPool "Show instances"
33 $ "num"
34 ∷ "reflection"
35 ∷ "tree"
36 ∷ []
37
38 textTests : TestPool
39 textTests = mkTestPool "Text libraries"
40 $ "pretty"
41 ∷ "printf"
42 ∷ "regex"
43 ∷ "tabular"
44 ∷ []
45
46 monadTests : TestPool
47 monadTests = mkTestPool "Monad transformers"
48 $ "counting"
49 ∷ "fibonacci"
50 ∷ "pythagorean"
51 ∷ "tcm"
52 ∷ []
53
54 reflectionTests : TestPool
55 reflectionTests = mkTestPool "Reflection machinery"
56 $ "assumption"
57 ∷ []
58
59 main : Main
60 main = run $ ignore $ runner
61 $ testPaths "data" dataTests
62 ∷ testPaths "monad" monadTests
63 ∷ testPaths "reflection" reflectionTests
64 ∷ testPaths "show" showTests
65 ∷ testPaths "system" systemTests
66 ∷ testPaths "text" textTests
67 ∷ [] where
68
69 testPaths : String → TestPool → TestPool
70 testPaths dir pool =
71 let testCases = List.map ((dir ++ "/") ++_) (pool .TestPool.testCases)
72 in record pool { testCases = testCases }