-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
move tests to testament #16101
move tests to testament #16101
Conversation
ringabout
commented
Nov 23, 2020
•
edited
Loading
edited
- change two or three unittest style to doAssert
- use include because some symbols are not exported
- disable testing random module
* move tests to testament * minor * fix random * disable test random (cherry picked from commit cbc793b)
* move tests to testament * minor * fix random * disable test random
@@ -665,36 +665,6 @@ proc prevPermutation*[T](x: var openArray[T]): bool {.discardable.} = | |||
|
|||
result = true | |||
|
|||
when isMainModule: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xflywind
after PR we now have both tests/stdlib/ttables.nim and tests/collections/ttables.nim
(but it was indeed better to delay fixing this to a separate PR so this one stays a simple move operation)
these should be merged into a single one
to review this PR, you really need |
let foo = parseUri("http://example.com") / "/baz" | ||
doAssert foo.path == "/baz" | ||
|
||
# bug found on stream 13/10/17 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for next time, prefer this style in 1 line:
block: # bug found on stream 13/10/17
- more consistent with block logic
- more similar to
block: label
- more similar to
test "VM and runtime should
in unittests - more common and shorter
@@ -52,7 +45,7 @@ suite "httpcore": | |||
doAssert parseHeader("Accept: foo, bar, prologue") == (key: "Accept", value: @["foo", "bar", "prologue"]) | |||
doAssert parseHeader("Accept: foo, bar, prologue, starlight") == (key: "Accept", value: @["foo", "bar", "prologue", "starlight"]) | |||
|
|||
test "add empty sequence to HTTP headers": | |||
block add_empty_sequence_to_HTTP_headers: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
prefer this style:
block: "add empty sequence to HTTP headers"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
* move tests to testament * minor * fix random * disable test random
* move tests to testament * minor * fix random * disable test random