Basic unit testing facilities (suites, fixtures, cases)

Added: PNimrodNode.lineinfo for better error messages from macros
Added: seq.splice

For easier use from templates and macros, except stament now supports
the list of exception types to be supplied in nkBraket node (array literal).
This commit is contained in:
Zahary Karadjov 2011-10-05 16:03:24 +03:00
commit 22546c44d1
8 changed files with 258 additions and 16 deletions

View file

@ -456,6 +456,12 @@ proc ToLinenumber*(info: TLineInfo): int {.inline.} =
proc toColumn*(info: TLineInfo): int {.inline.} =
result = info.col
proc toFileLine*(info: TLineInfo): string {.inline.} =
result = info.toFilename & ":" & $info.line
proc toFileLineCol*(info: TLineInfo): string {.inline.} =
result = info.toFilename & "(" & $info.line & "," & $info.col & ")"
var checkPoints: seq[TLineInfo] = @[]
proc addCheckpoint*(info: TLineInfo) =