make run the default action of a test in tester

This commit is contained in:
Arne Döring
2018-11-13 15:21:14 +01:00
committed by Araq
parent 610283b9b0
commit 031bfdec6f
50 changed files with 313 additions and 46 deletions

View File

@@ -1,6 +1,3 @@
discard """
"""
import os
import osproc
import parseopt2
@@ -13,7 +10,6 @@ if argv == @[]:
doAssert execShellCmd(getAppFilename() & " \"foo bar\" --aa:bar=a --a=c:d --ab -c --a[baz]:doo") == 0
else:
let f = toSeq(getopt())
echo f.repr
doAssert f[0].kind == cmdArgument and f[0].key == "foo bar" and f[0].val == ""
doAssert f[1].kind == cmdLongOption and f[1].key == "aa" and f[1].val == "bar=a"
doAssert f[2].kind == cmdLongOption and f[2].key == "a=c" and f[2].val == "d"