xref: /curl/tests/data/test1426 (revision 18f1cd7a)
1<testcase>
2<info>
3<keywords>
4HTTP
5binary-stdout
6</keywords>
7</info>
8
9<reply>
10<real_data>
11HTTP/1.1 200 OK
12Date: Tue, 09 Nov 2010 14:49:00 GMT
13Server: test-server/fake
14Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
15ETag: 21025-dc7-39462498
16Accept-Ranges: bytes
17Content-Length: 5
18Connection: close
19Content-Type: text/html
20Funny-head: yesyes
21
22�1234
23</real_data>
24
25# Provided as base64 encoded to get the binary zero in the body treated
26# properly. Tricky to generate correctly.
27<data base64="yes" nocheck="yes">
28SFRUUC8xLjEgMjAwIE9LCkRhdGU6IFR1ZSwgMDkgTm92IDIwMTAgMTQ6NDk6MDAgR01UClNlcnZl
29cjogdGVzdC1zZXJ2ZXIvZmFrZQpMYXN0LU1vZGlmaWVkOiBUdWUsIDEzIEp1biAyMDAwIDEyOjEw
30OjAwIEdNVApFVGFnOiAyMTAyNS1kYzctMzk0NjI0OTgKQWNjZXB0LVJhbmdlczogYnl0ZXMKQ29u
31dGVudC1MZW5ndGg6IDUKQ29ubmVjdGlvbjogY2xvc2UKQ29udGVudC1UeXBlOiB0ZXh0L2h0bWwK
32RnVubnktaGVhZDogeWVzeWVzCgoAMTIzNAo=
33</data>
34</reply>
35
36#
37# Client-side
38<client>
39<server>
40http
41</server>
42
43# this test needs to be a debug build in order to fake it being a TTY output
44<features>
45Debug
46</features>
47<setenv>
48CURL_ISATTY=yes
49</setenv>
50<name>
51Okay binary output to terminal
52</name>
53<command>
54http://%HOSTIP:%HTTPPORT/%TESTNUMBER --output -
55</command>
56</client>
57
58#
59# Verify data after the test has been "shot"
60<verify>
61<protocol>
62GET /%TESTNUMBER HTTP/1.1
63Host: %HOSTIP:%HTTPPORT
64User-Agent: curl/%VERSION
65Accept: */*
66
67</protocol>
68<stdout nonewline="yes">
69HTTP/1.1 200 OK
70Date: Tue, 09 Nov 2010 14:49:00 GMT
71Server: test-server/fake
72Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
73ETag: 21025-dc7-39462498
74Accept-Ranges: bytes
75Content-Length: 5
76Connection: close
77Content-Type: text/html
78Funny-head: yesyes
79
80�1234
81</stdout>
82</verify>
83</testcase>
84