quickjs-tart

quickjs-based runtime for wallet-core logic
Log | Files | Refs | README | LICENSE

test391 (978B)


      1 <testcase>
      2 <info>
      3 <keywords>
      4 HTTP
      5 HTTP GET
      6 --path-as-is
      7 </keywords>
      8 </info>
      9 
     10 #
     11 # Server-side
     12 <reply>
     13 <data>
     14 HTTP/1.1 301 OK
     15 Content-Length: 6
     16 Content-Type: text/html
     17 Location: ../%TESTNUMBER0002
     18 
     19 -foo-
     20 </data>
     21 <data2>
     22 HTTP/1.1 200 OK
     23 Content-Length: 6
     24 Content-Type: text/html
     25 
     26 -muu-
     27 </data2>
     28 <datacheck>
     29 HTTP/1.1 301 OK
     30 Content-Length: 6
     31 Content-Type: text/html
     32 Location: ../%TESTNUMBER0002
     33 
     34 HTTP/1.1 200 OK
     35 Content-Length: 6
     36 Content-Type: text/html
     37 
     38 -muu-
     39 </datacheck>
     40 </reply>
     41 
     42 #
     43 # Client-side
     44 <client>
     45 <server>
     46 http
     47 </server>
     48 <name>
     49 --path-as-is with redirect, keeping dotdots
     50 </name>
     51 <command>
     52 http://%HOSTIP:%HTTPPORT/../../%TESTNUMBER --path-as-is -L
     53 </command>
     54 </client>
     55 
     56 #
     57 # Verify data after the test has been "shot"
     58 <verify>
     59 <protocol>
     60 GET /../../%TESTNUMBER HTTP/1.1
     61 Host: %HOSTIP:%HTTPPORT
     62 User-Agent: curl/%VERSION
     63 Accept: */*
     64 
     65 GET /%TESTNUMBER0002 HTTP/1.1
     66 Host: %HOSTIP:%HTTPPORT
     67 User-Agent: curl/%VERSION
     68 Accept: */*
     69 
     70 </protocol>
     71 </verify>
     72 </testcase>