Skip to content
Igor Gursky edited this page Sep 23, 2016 · 4 revisions

Adding Accept header

Given accept mediaType is JSON 
  or
Given accept "application/json" mediaTypes

Adding Content-Type header

Given content type is JSON
  or
Given content type is "application/json"

Adding custom HTTP header

Given header Custom-Header with value "custom-value"

Copying a value from Response HTTP header

Given request body from file gadgets/requests/newGadget.json
When the client performs POST request on /gadgets
Then let variable "gadgetURL" equal to header "Location" value

Asserting headers

Then header Accept equal to "application/json"

Then header Accept contains "application/"

Then header Accept does not contain "invalid-value"

Then header Custom-Header ends with pattern "d+"

Then header Invalid-Header is empty

Then header Accept is not empty

Then header Accept not equal to "application/xml"
Clone this wiki locally