hasContentType function
Matches a response with Content-Type containing the given type.
Example:
expect(res, hasContentType('application/json'));
expect(res, hasContentType('text/html'));
Implementation
Matcher hasContentType(String type) =>
hasHeader('content-type', contains(type));