This commit is contained in:
parent
8922063bd8
commit
1d941b8735
1 changed files with 8 additions and 3 deletions
|
|
@ -18,6 +18,7 @@ var useColors = true
|
||||||
var backendLogging = true
|
var backendLogging = true
|
||||||
var simulate = false
|
var simulate = false
|
||||||
var verboseMegatest = false # very verbose but can be useful
|
var verboseMegatest = false # very verbose but can be useful
|
||||||
|
var verboseCommands = false
|
||||||
|
|
||||||
const
|
const
|
||||||
testsDir = "tests" & DirSep
|
testsDir = "tests" & DirSep
|
||||||
|
|
@ -37,6 +38,7 @@ Arguments:
|
||||||
Options:
|
Options:
|
||||||
--print also print results to the console
|
--print also print results to the console
|
||||||
--verboseMegatest log to stdout megatetest compilation
|
--verboseMegatest log to stdout megatetest compilation
|
||||||
|
--verboseCommands log to stdout info about commands being run
|
||||||
--simulate see what tests would be run but don't run them (for debugging)
|
--simulate see what tests would be run but don't run them (for debugging)
|
||||||
--failing only show failing/ignored tests
|
--failing only show failing/ignored tests
|
||||||
--targets:"c c++ js objc" run tests for specified targets (default: all)
|
--targets:"c c++ js objc" run tests for specified targets (default: all)
|
||||||
|
|
@ -111,12 +113,14 @@ proc execCmdEx2(command: string, args: openarray[string], options: set[ProcessOp
|
||||||
result.exitCode = peekExitCode(p)
|
result.exitCode = peekExitCode(p)
|
||||||
if result.exitCode != -1: break
|
if result.exitCode != -1: break
|
||||||
close(p)
|
close(p)
|
||||||
if result.exitCode != 0:
|
|
||||||
|
if verboseCommands:
|
||||||
var command2 = command
|
var command2 = command
|
||||||
if args.len > 0: command2.add " " & args.quoteShellCommand
|
if args.len > 0: command2.add " " & args.quoteShellCommand
|
||||||
echo (msg: "execCmdEx2 failed",
|
echo (msg: "execCmdEx2",
|
||||||
command: command2,
|
command: command2,
|
||||||
options: options)
|
options: options,
|
||||||
|
exitCode: result.exitCode)
|
||||||
|
|
||||||
proc nimcacheDir(filename, options: string, target: TTarget): string =
|
proc nimcacheDir(filename, options: string, target: TTarget): string =
|
||||||
## Give each test a private nimcache dir so they don't clobber each other's.
|
## Give each test a private nimcache dir so they don't clobber each other's.
|
||||||
|
|
@ -540,6 +544,7 @@ proc main() =
|
||||||
case p.key.string.normalize
|
case p.key.string.normalize
|
||||||
of "print", "verbose": optPrintResults = true
|
of "print", "verbose": optPrintResults = true
|
||||||
of "verbosemegatest": verboseMegatest = true
|
of "verbosemegatest": verboseMegatest = true
|
||||||
|
of "verbosecommands": verboseCommands = true
|
||||||
of "failing": optFailing = true
|
of "failing": optFailing = true
|
||||||
of "pedantic": discard "now always enabled"
|
of "pedantic": discard "now always enabled"
|
||||||
of "targets":
|
of "targets":
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue