1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

ci: fix request_test.v (add missing \r to hardcoded post data)

This commit is contained in:
Delyan Angelov
2021-11-10 18:15:39 +02:00
parent 466ced2876
commit 3c6356ba36
2 changed files with 21 additions and 10 deletions

View File

@ -103,16 +103,16 @@ fn test_parse_multipart_form() {
file := 'bar.v'
ct := 'application/octet-stream'
contents := ['baz', 'buzz']
data := "--------------------------$boundary
Content-Disposition: form-data; name=\"${names[0]}\"; filename=\"$file\"
Content-Type: $ct
${contents[0]}
--------------------------$boundary
Content-Disposition: form-data; name=\"${names[1]}\"
${contents[1]}
--------------------------$boundary--
data := "--$boundary
Content-Disposition: form-data; name=\"${names[0]}\"; filename=\"$file\"\r
Content-Type: $ct\r
\r
${contents[0]}\r
--$boundary\r
Content-Disposition: form-data; name=\"${names[1]}\"\r
\r
${contents[1]}\r
--$boundary--\r
"
form, files := parse_multipart_form(data, boundary)
assert files == {