Skip to content

Commit 6f31a11

Browse files
committed
Fix test_unsupported_compression: use bzip2 instead of jpeg
JPEG is now a supported codec, so passing it with float32 data hits the dtype validation before the unsupported-compression check. Use bzip2 (actually unsupported) to test the right error path.
1 parent 8895419 commit 6f31a11

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

xrspatial/geotiff/tests/test_writer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,4 @@ class TestWriteInvalidInput:
101101
def test_unsupported_compression(self, tmp_path):
102102
arr = np.zeros((4, 4), dtype=np.float32)
103103
with pytest.raises(ValueError, match="Unsupported compression"):
104-
write(arr, str(tmp_path / 'bad.tif'), compression='jpeg')
104+
write(arr, str(tmp_path / 'bad.tif'), compression='bzip2')

0 commit comments

Comments
 (0)