Skip to content

Commit 0610168

Browse files
committed
Merge remote-tracking branch 'origin/master' into client
2 parents a0cb065 + 7c6a9e8 commit 0610168

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

tests/test_exceptions.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,9 +119,11 @@ def test_bad_image(client: VWS) -> None:
119119
A ``BadImage`` exception is raised when a non-image is given.
120120
"""
121121
not_an_image = io.BytesIO(b'Not an image')
122-
with pytest.raises(BadImage):
122+
with pytest.raises(BadImage) as exc:
123123
client.add_target(name='x', width=1, image=not_an_image)
124124

125+
assert exc.value.response.status_code == codes.UNPROCESSABLE_ENTITY
126+
125127

126128
def test_target_name_exist(
127129
client: VWS,

0 commit comments

Comments
 (0)