use doAssert in tests (#16486)

This commit is contained in:
flywind 2020-12-28 07:13:21 -06:00 • committed by GitHub
commit 6d442a40a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
78 changed files with 1056 additions and 1056 deletions

View file

@ -468,19 +468,19 @@ block isRelativeTo:
doAssert not isRelativeTo("/foo2", "/foo")
block: # quoteShellWindows
assert quoteShellWindows("aaa") == "aaa"
assert quoteShellWindows("aaa\"") == "aaa\\\""
assert quoteShellWindows("") == "\"\""
doAssert quoteShellWindows("aaa") == "aaa"
doAssert quoteShellWindows("aaa\"") == "aaa\\\""
doAssert quoteShellWindows("") == "\"\""
block: # quoteShellWindows
assert quoteShellPosix("aaa") == "aaa"
assert quoteShellPosix("aaa a") == "'aaa a'"
assert quoteShellPosix("") == "''"
assert quoteShellPosix("a'a") == "'a'\"'\"'a'"
doAssert quoteShellPosix("aaa") == "aaa"
doAssert quoteShellPosix("aaa a") == "'aaa a'"
doAssert quoteShellPosix("") == "''"
doAssert quoteShellPosix("a'a") == "'a'\"'\"'a'"
block: # quoteShell
when defined(posix):
assert quoteShell("") == "''"
doAssert quoteShell("") == "''"
block: # normalizePathEnd
# handle edge cases correctly: shouldn't affect whether path is