mirror of
https://github.com/curl/curl.git
synced 2024-12-15 06:40:09 +08:00
3fd80c7b59
The threee tags `<name>`, `</name>` and `<command>` were frequently used with a leading space that this removes. The reason this habbit is so widespread in testcases is probably that they have been copy and pasted. Hence, fixing them all now might curb this practice from now on. Closes #12028
66 lines
940 B
Plaintext
66 lines
940 B
Plaintext
<testcase>
|
|
<info>
|
|
<keywords>
|
|
HTTP
|
|
HTTP POST
|
|
chunked Transfer-Encoding
|
|
config file
|
|
-A
|
|
</keywords>
|
|
</info>
|
|
# Server-side
|
|
<reply>
|
|
<data>
|
|
HTTP/1.0 200 OK swsclose
|
|
Funny-head: yesyes
|
|
|
|
This is the proof it works
|
|
</data>
|
|
</reply>
|
|
|
|
# Client-side
|
|
<client>
|
|
<server>
|
|
http
|
|
</server>
|
|
<name>
|
|
HTTP POST with *HUGE* request and chunked transfer-encoding
|
|
</name>
|
|
<stdin>
|
|
#
|
|
data "we post this"
|
|
#
|
|
# enforce chunky post!
|
|
header "Transfer-Encoding: chunked"
|
|
#
|
|
# Set the user-agent using a short-option:
|
|
-A "%repeat[99999 x a]%"
|
|
#
|
|
</stdin>
|
|
<command>
|
|
-K - %HOSTIP:%HTTPPORT/that.site.com/%TESTNUMBER
|
|
</command>
|
|
</client>
|
|
|
|
# Verify data after the test has been "shot"
|
|
<verify>
|
|
<protocol>
|
|
POST /that.site.com/%TESTNUMBER HTTP/1.1
|
|
Host: %HOSTIP:%HTTPPORT
|
|
User-Agent: %repeat[99999 x a]%
|
|
Accept: */*
|
|
Transfer-Encoding: chunked
|
|
Content-Type: application/x-www-form-urlencoded
|
|
|
|
%if hyper
|
|
C
|
|
%else
|
|
c
|
|
%endif
|
|
we post this
|
|
0
|
|
|
|
</protocol>
|
|
</verify>
|
|
</testcase>
|