def test_bad_json_response(self, mock_request): mock_request.return_value = self.mock_response(self.json_response, bad_json=True) r = pystmark.get_bounce_dump(self.bounce_id, test=True) self.assertIs(r.dump, None)
def test_simple_api(self, mock_request): mock_request.return_value = self.mock_response(self.json_response) r = pystmark.get_bounce_dump(self.bounce_id, test=True) self.assertValidJSONResponse(r, self.response)
def test_get_bounce_dump(self): r = pystmark.get_bounce_dump(777, test=True) self.assert500(r)