Skip to content

Commit

Permalink
test: Linter fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Marsmaennchen221 committed Dec 8, 2023
1 parent 2506d5c commit 7ad66e4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/safeds/data/image/containers/test_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,10 @@ class TestFromBytes:
def test_should_write_and_load_bytes_jpeg(self, resource_path: str | Path, device: Device) -> None:
_skip_if_device_not_available(device)
image = Image.from_file(resolve_resource_path(resource_path), device)
image_copy = Image.from_bytes(bytes(image._repr_jpeg_()), device)
repr_jpeg = image._repr_jpeg_()
if repr_jpeg is None:
assert False # Linter fix; should always be not None
image_copy = Image.from_bytes(repr_jpeg, device)
assert image == image_copy

@pytest.mark.parametrize(
Expand Down

0 comments on commit 7ad66e4

Please sign in to comment.