Add "safety compilation". Improved, fixed messages

- node ext searcher also looks for "iojs" if no node(js?) found.
- koch ensures the local work dir compiler is freshly compiled before executing the tests.
- the tester can only run in the repo dir - now the compiler and libs used are also explicitly the local dirs - so no confusion from system wide pathing ("sufficiently sandboxed").
- fixed expectations in tmitems.nim test to match changes in json mod.
- re-layouted the columns / row printing slightly, making test fails pop out more, and everything "normal" layed back.
This commit is contained in:
Oscar Campbell 2015-06-04 07:33:27 +02:00
commit 071ccf3d02
4 changed files with 100 additions and 58 deletions

View file

@ -330,12 +330,12 @@ proc winRelease() =
template `|`(a, b): expr = (if a.len > 0: a else: b)
proc tests(args: string) =
# Since tests take a long time (on my machine) - lets make sure a stupid
# mistake - like forgetting to compile the compiler - isn't made...
exec "nim c --lib:lib -d:release compiler/nim.nim"
# we compile the tester with taintMode:on to have a basic
# taint mode test :-)
exec "nim cc --taintMode:on tests/testament/tester"
# Since tests take a long time (on my machine), and we want to defy Murhpys
# law - lets make sure the compiler really is freshly compiled!
exec "nim c --lib:lib -d:release --opt:speed compiler/nim.nim"
let tester = quoteShell(getCurrentDir() / "tests/testament/tester".exe)
let success = tryExec tester & " " & (args|"all")
exec tester & " html"