unittest bugfix; made some tests green

This commit is contained in:
Araq
2012-09-08 22:33:15 +02:00
parent 580d85d233
commit 46f652b93e
3 changed files with 6 additions and 4 deletions

View File

@@ -92,7 +92,7 @@ template fail* =
TestStatusIMPL = FAILED
checkpoints = @[]
macro check*(conditions: stmt): stmt =
macro check*(conditions: stmt): stmt {.immediate.} =
let conditions = callsite()
proc standardRewrite(e: PNimrodNode): PNimrodNode =
@@ -153,7 +153,7 @@ template require*(conditions: stmt): stmt {.dirty.} =
const AbortOnError {.inject.} = true
check conditions
macro expect*(exp: stmt): stmt =
macro expect*(exp: stmt): stmt {.immediate.} =
let exp = callsite()
template expectBody(errorTypes, lineInfoLit: expr,
body: stmt): PNimrodNode {.dirty.} =