diff options
author | Arne Döring <arne.doering@gmx.net> | 2018-11-28 00:05:15 +0100 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2018-12-11 21:23:18 +0100 |
commit | 7f6feb603441ed08e3c0b55d91dd34234d30ea58 (patch) | |
tree | 8ff5e0196c441b18e3dc4797782a0cffa95ad086 | |
parent | 7b40c864bc4842f704855188010cea468c89f98c (diff) | |
download | Nim-7f6feb603441ed08e3c0b55d91dd34234d30ea58.tar.gz |
minor changes
-rw-r--r-- | testament/tester.nim | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/testament/tester.nim b/testament/tester.nim index 1c105c97f..60cf46423 100644 --- a/testament/tester.nim +++ b/testament/tester.nim @@ -353,7 +353,6 @@ proc testSpec(r: var TResults, test: TTest, targets: set[TTarget] = {}) = else: specDefaults expected expected.action = actionRunNoSpec - expected.outputCheck = ocIgnore # this is default so it is unnecessary if expected.err == reIgnored: # targetC is a lie @@ -498,9 +497,7 @@ proc testExec(r: var TResults, test: TTest) = if given.err == reSuccess: inc(r.passed) r.addResult(test, targetC, "", given.msg, given.err) -proc makeTest(test, options: string, cat: Category, - env: string = ""): TTest = - # start with 'actionCompile', will be overwritten in the spec: +proc makeTest(test, options: string, cat: Category, env: string = ""): TTest = result = TTest(cat: cat, name: test, options: options, startTime: epochTime()) when defined(windows): @@ -526,10 +523,8 @@ proc main() = backend.open() var optPrintResults = false var optFailing = false - var targetsStr = "" - var p = initOptParser() p.next() while p.kind == cmdLongoption: @@ -544,16 +539,18 @@ proc main() = of "directory": setCurrentDir(p.val.string) of "colors": - if p.val.string == "on": + case p.val.string: + of "on": useColors = true - elif p.val.string == "off": + of "off": useColors = false else: quit Usage else: quit Usage p.next() - if p.kind != cmdArgument: quit Usage + if p.kind != cmdArgument: + quit Usage var action = p.key.string.normalize p.next() var r = initResults() |