Esempio n. 1
0
    def test_normal_content_type(self):
        response = Response(
            status_code=200,
            body='hello',
            headers={'content-type': 'application/json; charset=utf8'})

        assert response.content_type == 'application/json'
Esempio n. 2
0
    def test_no_content_type(self):
        response = Response(status_code=200, body='hello', headers={})

        assert not response.content_type