quickjs-tart

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

test437 (1170B)


      1 <testcase>
      2 <info>
      3 <keywords>
      4 HTTP
      5 Alt-Svc
      6 </keywords>
      7 </info>
      8 
      9 #
     10 # Server-side
     11 <reply>
     12 <data>
     13 HTTP/1.1 200 OK
     14 Date: Tue, 09 Nov 2010 14:49:00 GMT
     15 Content-Length: 6
     16 Connection: close
     17 Content-Type: text/html
     18 Funny-head: yesyes
     19 Alt-Svc: h1="[ffff::1]:8181"
     20 
     21 -foo-
     22 </data>
     23 </reply>
     24 
     25 #
     26 # Client-side
     27 <client>
     28 <features>
     29 Debug
     30 alt-svc
     31 IPv6
     32 </features>
     33 <server>
     34 http
     35 </server>
     36 <name>
     37 Alt-Svc to numerical IPv6 address
     38 </name>
     39 <setenv>
     40 # make debug-curl accept Alt-Svc over plain HTTP
     41 CURL_ALTSVC_HTTP="yeah"
     42 </setenv>
     43 <command>
     44 http://%HOSTIP:%HTTPPORT/%TESTNUMBER --alt-svc "%LOGDIR/altsvc-%TESTNUMBER"
     45 </command>
     46 </client>
     47 
     48 #
     49 # Verify data after the test has been "shot"
     50 <verify>
     51 <protocol>
     52 GET /%TESTNUMBER HTTP/1.1
     53 Host: %HOSTIP:%HTTPPORT
     54 User-Agent: curl/%VERSION
     55 Accept: */*
     56 
     57 </protocol>
     58 <stripfile>
     59 # strip out the (dynamic) expire date from the file so that the rest
     60 # matches
     61 s/\"([^\"]*)\"/TIMESTAMP/
     62 </stripfile>
     63 <file name="%LOGDIR/altsvc-%TESTNUMBER" mode="text">
     64 # Your alt-svc cache. https://curl.se/docs/alt-svc.html
     65 # This file was generated by libcurl! Edit at your own risk.
     66 h1 %HOSTIP %HTTPPORT h1 [ffff::1] 8181 TIMESTAMP 0 0
     67 </file>
     68 </verify>
     69 </testcase>