diff --git a/testament/testament.nim b/testament/testament.nim index 63e5781..e5820ad 100644 --- a/testament/testament.nim +++ b/testament/testament.nim @@ -649,14 +649,21 @@ proc main() = var targetsStr = "" var isMainProcess = true var skipFrom = "" + var myargs = "" var p = initOptParser() p.next() while p.kind in {cmdLongOption, cmdShortOption}: case p.key.normalize - of "print": optPrintResults = true - of "verbose": optVerbose = true - of "failing": optFailing = true + of "print": + myargs &= " --" & p.key.normalize + optPrintResults = true + of "verbose": + myargs &= " --" & p.key.normalize + optVerbose = true + of "failing": + myargs &= " --" & p.key.normalize + optFailing = true of "pedantic": discard # deadcode refs https://github.com/nim-lang/Nim/issues/16731 of "targets": targetsStr = p.val @@ -667,6 +674,7 @@ proc main() = of "directory": setCurrentDir(p.val) of "colors": + myargs &= " --" & p.key.normalize & ":" & p.val case p.val: of "on": useColors = true @@ -694,6 +702,7 @@ proc main() = else: quit Usage of "backendlogging": + myargs &= " --" & p.key.normalize & ":" & p.val case p.val: of "on": backendLogging = true @@ -715,7 +724,7 @@ proc main() = of "all": #processCategory(r, Category"megatest", p.cmdLineRest, testsDir, runJoinableTests = false) - var myself = quoteShell(getAppFilename()) + var myself = quoteShell(getAppFilename()) & myargs if targetsStr.len > 0: myself &= " " & quoteShell("--targets:" & targetsStr)