Use accessor instead of low level header value in tests
The test was failing in recent Catalyst versions because it was fetching
the header value using $res->header('Content-Type') instead of
$res->content_type. The former would get the entire HTTP header, which
recent versions would append the charset, thus changing the expected
value from 'text/x-yaml' to 'text/x-yaml; charset=UTF-8'.
The ->content_type accessor parses the header, and returns (in the
example): ('text/x-yaml', 'charset=UTF-8') in list context, and simply
'text/x-yaml' in scalar context. Using this, the test doesn't have to
worry about low level details such as the charset defined, which is out
of the scope of the test.