Add some tests to httpcore related to #5344.
This commit is contained in:
parent
8ae05c6555
commit
7c15120247
1 changed files with 7 additions and 0 deletions
|
|
@ -312,3 +312,10 @@ when isMainModule:
|
|||
test.add("Connection", "Test")
|
||||
doAssert test["Connection", 2] == "Test"
|
||||
doAssert "upgrade" in test["Connection"]
|
||||
|
||||
# Bug #5344.
|
||||
doAssert parseHeader("foobar: ") == ("foobar", @[""])
|
||||
let (key, value) = parseHeader("foobar: ")
|
||||
test = newHttpHeaders()
|
||||
test[key] = value
|
||||
doAssert test["foobar"] == ""
|
||||
Loading…
Add table
Add a link
Reference in a new issue