HsacAcceptanceTests.SlimTests.HttpTest.PollingTests.HttpByHeaderTest


We retry a call until a header of the response is a certain value.

Setup server


script mock xml server setup
add response response
add response 1 response
add response 11 response
add response another response
add response yet another response
$url<-[http://127.0.0.1:8000/FitNesseMock] get mock server url


script json http test
check repeat interval 100
set repeat interval to 50 milliseconds
repeat at most 2 times
post 0 request to $url->[http://127.0.0.1:8000/FitNesseMock]
repeat until header Content-length is 8
check response header Content-length 8
post 0 request to $url->[http://127.0.0.1:8000/FitNesseMock]
repeat until header Content-length is 11
check response header Content-length 11
repeat at most 1 times
reject repeat until header Not present is bla
check response another response
repeat until header Not present either is null
check response header Not present either null
check repeat count 0
show response another response








Stop Server

table: Mock Server Message Report
1 (of 5) request(s) did not match expectation
1

request

0 request

response

response
2

request

0 request

response

1 response
3

request

0 request

response

11 response
4

request

0 request

response

another response
5No request received

response

yet another response

script mock xml server setup
stop