-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
change define prefix and update docs (#7)
- Loading branch information
1 parent
c847fc3
commit b9b61cf
Showing
6 changed files
with
1,394 additions
and
1,377 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,24 @@ | ||
task test, "Run tests": | ||
let | ||
xmlFile = "test_results.xml" | ||
commandStart = "nim c -r -f --threads:on --hints:off --verbosity:0 --skipParentCfg:on --skipUserCfg:on " | ||
|
||
for f in listFiles("tests"): | ||
if f.len > 4 and f[^4..^1] == ".nim": | ||
let cmd = "nim c -r -f --threads:on --hints:off --verbosity:0 --skipParentCfg:on --skipUserCfg:on " & f | ||
# This should generate an XML results file. | ||
var cmd = commandStart & f & " --xml:" & xmlFile & " --console" | ||
echo cmd | ||
exec cmd | ||
rmFile(f[0..^5].toExe()) | ||
doAssert fileExists xmlFile | ||
rmFile xmlFile | ||
|
||
# This should not, since we disable param processing. | ||
cmd = commandStart & "-d:unittest2DisableParamFiltering " & f & " --xml:" & xmlFile | ||
echo cmd | ||
exec cmd | ||
doAssert not fileExists xmlFile | ||
rmFile f[0..^5].toExe | ||
|
||
task buildDocs, "Build docs": | ||
exec "nim doc --skipParentCfg:on --skipUserCfg:on --git.url:https://github.com/status-im/nim-unittest2 --git.commit:master --git.devel:master unittest2.nim" | ||
|
Oops, something went wrong.