We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 54e3e67 commit 914b219Copy full SHA for 914b219
tests/test_exceptions.py
@@ -95,9 +95,11 @@ def test_bad_image(client: VWS) -> None:
95
A ``BadImage`` exception is raised when a non-image is given.
96
"""
97
not_an_image = io.BytesIO(b'Not an image')
98
- with pytest.raises(BadImage):
+ with pytest.raises(BadImage) as exc:
99
client.add_target(name='x', width=1, image=not_an_image)
100
101
+ assert exc.value.response.status_code == codes.UNPROCESSABLE_ENTITY
102
+
103
104
def test_target_name_exist(
105
client: VWS,
0 commit comments