MCPcopy
hub / github.com/scrapinghub/splash / assertStatusCode

Method assertStatusCode

splash/tests/test_render.py:84–87  ·  view source on GitHub ↗
(self, response, code)

Source from the content-addressed store, hash-verified

82 return self._get_handler().post(query, endpoint, payload, headers, **kwargs)
83
84 def assertStatusCode(self, response, code):
85 msg = (response.status_code, truncated(response.text, 1000),
86 response.url)
87 self.assertEqual(response.status_code, code, msg)
88
89 def assertJsonError(self, response, code, error_type=None):
90 self.assertStatusCode(response, code)

Callers 15

assertJsonErrorMethod · 0.95
assertPngMethod · 0.95
assertJpegMethod · 0.95
test_viewportMethod · 0.80
assertRedirectedMethod · 0.80
assertNotRedirectedMethod · 0.80
assertRedirectedMethod · 0.80
assertNotRedirectedMethod · 0.80
test_render_errorMethod · 0.80
test_timeoutMethod · 0.80

Calls 1

truncatedFunction · 0.90

Tested by

no test coverage detected