This was causing me the issue. It was looking for only 'json' as defined by CONTENT_TYPE_JSON. It wasn't looking through the whole string to find the 'json' at the end. The tests are using 'application\hal+json' and failing.