xref: /curl/tests/data/test458 (revision c20f4251)
1<testcase>
2<info>
3<keywords>
4HTTP
5variables
6</keywords>
7</info>
8
9#
10# Server-side
11<reply>
12<data crlf="yes" nocheck="yes">
13HTTP/1.1 200 OK
14Date: Tue, 09 Nov 2010 14:49:00 GMT
15Server: test-server/fake
16Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
17ETag: "21025-dc7-39462498"
18Accept-Ranges: bytes
19Content-Length: 6
20Connection: close
21Content-Type: text/html
22Funny-head: yesyes
23
24-foo-
25</data>
26</reply>
27
28#
29# Client-side
30<client>
31<server>
32http
33</server>
34<setenv>
35FUNVALUE=contents%TESTNUMBER
36VALUE2=curl
37BLANK=
38</setenv>
39<name>
40variable expand the file name with --expand-output
41</name>
42<file name="%LOGDIR/cmd">
43--variable %FUNVALUE
44--expand-output %LOGDIR/{{FUNVALUE}}
45</file>
46<command option="no-output">
47http://%HOSTIP:%HTTPPORT/%TESTNUMBER -K %LOGDIR/cmd
48</command>
49</client>
50
51#
52# Verify data after the test has been "shot"
53<verify>
54<protocol crlf="yes">
55GET /%TESTNUMBER HTTP/1.1
56Host: %HOSTIP:%HTTPPORT
57User-Agent: curl/%VERSION
58Accept: */*
59
60</protocol>
61<file name="%LOGDIR/contents%TESTNUMBER" crlf="yes">
62HTTP/1.1 200 OK
63Date: Tue, 09 Nov 2010 14:49:00 GMT
64Server: test-server/fake
65Last-Modified: Tue, 13 Jun 2000 12:10:00 GMT
66ETag: "21025-dc7-39462498"
67Accept-Ranges: bytes
68Content-Length: 6
69Connection: close
70Content-Type: text/html
71Funny-head: yesyes
72
73-foo-
74</file>
75</verify>
76</testcase>
77