Test failures with Python 3.13
Closed this issue · 1 comments
juliangilbey commented
Hi!
Python 3.13 has changed the message associated with HTTP code 422 from 'Unprocessable Entity' to 'Unprocessable Content', which breaks three tests:
FAILED tests/renderers/httpdomain/test_render_response.py::test_render_response_content_custom[422]
FAILED tests/renderers/httpdomain/test_render_response_example.py::test_render_response_status_code[422]
FAILED tests/renderers/httpdomain/test_render_response_example.py::test_render_response_status_code_int[422]
So these tests require some sort of conditional to change the expected output depending on the Python version. I don't know how to do this "nicely", though.
juliangilbey commented
Actually, I spoke too soon; it seems quite straightforward, and I have made a PR to fix this.