def test__when_method_raises_github_exception__should_return_its_status__and_data_as_reason(self):
@handle_exceptions()
async def github_exception_raising_coro():
raise github.GithubException(404, {'message': 'Not found'})
response: aiohttp.web.Response = await github_exception_raising_coro()
assert response.status == 404
assert response.reason == "{'message': 'Not found'}"
评论列表
文章目录