Accept Headers
-
Assert that a GET request to "/api/level17" returns a 200 status code.
-
Assert that a GET request to "/api/level17" with a header of "Accept" with a value of "text/plain" returns the
response:
Here's some plain text!
-
Assert that a GET request to "/api/level17" with header of "Accept" with a value of "application/json" returns
the response:
{
"Hereees": "json!"
}