Add test discovery for easy test writing

This commit is contained in:
Joey Yakimowich-Payne 2019-11-04 15:03:28 -07:00
commit 502ca5329b
5 changed files with 49 additions and 13 deletions

View file

@ -1 +1,2 @@
-d:test
--path:"../src/"

3
tests/runner.nim Normal file
View file

@ -0,0 +1,3 @@
import tani
discoverAndRunTests()

6
tests/stuff/testham.nim Normal file
View file

@ -0,0 +1,6 @@
import tani
test "this is crazy":
echo "balls"
runTests()

View file

@ -1,4 +1,4 @@
import tani, test2
import tani
import terminal
import os
@ -20,4 +20,4 @@ proc y(): int =
return 10
runTestsMain()
runTests()