Logo: Relish

  1. Sign in

Project: Gavel 3.0.0

Headers

  • @javascript
Background
Given
you expect the following HTTP headers:
Content-Type: text/plain
Date: Fri, 31 Dec 1999 23:59:59 GMT
Location: /here
ETag: 68b329da9893e34099c7d8ad5cb9c940
Scenarios
  • @stable
Header is missing in real payload
When
real HTTP headers are following:
Content-Type: text/plain
Then
field "headers" is NOT valid
And
Request or Response is NOT valid
  • @stable
Extra real header in real payload
When
real HTTP headers are following:
Content-Type: text/plain
Content-Length: 1354
Date: Fri, 31 Dec 1999 23:59:59 GMT
Location: /here
ETag: 68b329da9893e34099c7d8ad5cb9c940
Then
field "headers" is valid
And
Request or Response is valid
  • @stable
Content nogotiation significant header value is different in real payload
When
real HTTP headers are following:
Content-Type: application/json
Date: Fri, 31 Dec 1999 23:59:59 GMT
Location: /here
ETag: 68b329da9893e34099c7d8ad5cb9c940
Then
field "headers" is NOT valid
And
Request or Response is NOT valid
  • @stable
Content negotiation not significant header value is different in real payload
When
real HTTP headers are following:
Content-Type: text/plain
Date: Fri, 13 Dec 3000 23:59:59 GMT
Location: /there
ETag: something-completely-different
Then
field "headers" is valid
And
Request or Response is valid

Last published 1 day ago by honzajavorek.