File tree Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change 1
1
module Main (main ) where
2
2
3
3
import EasyTest
4
+ import System.Environment (getArgs )
5
+ import System.IO
4
6
import System.IO.CodePage (withCP65001 )
5
7
import Unison.Test.Doc qualified as Doc
6
8
import Unison.Test.Unison qualified as Unison
7
9
10
+ -- main :: IO ()
11
+ -- main = withCP65001 . run $ tests [Unison.test, Doc.test]
12
+
13
+ test :: Test ()
14
+ test =
15
+ tests
16
+ [ Doc. test,
17
+ Unison. test
18
+ ]
19
+
8
20
main :: IO ()
9
- main = withCP65001 . run $ tests [Unison. test, Doc. test]
21
+ main = withCP65001 do
22
+ args <- getArgs
23
+ mapM_ (`hSetEncoding` utf8) [stdout, stdin, stderr]
24
+ case args of
25
+ [] -> runOnly " " test
26
+ [prefix] -> runOnly prefix test
27
+ [seed, prefix] -> rerunOnly (read seed) prefix test
28
+ _ -> error " expected no args, a prefix, or a seed and a prefix"
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import Unison.Util.Recursion
15
15
16
16
test :: Test ()
17
17
test =
18
- scope " Doc parser " . tests $
18
+ scope " DocParser " . tests $
19
19
[ t " # Hello" [Doc. Section (Doc. Paragraph $ docWord " Hello" :| [] ) [] ],
20
20
t
21
21
( unlines
You can’t perform that action at this time.
0 commit comments