Skip to content

Commit 3957d56

Browse files
committed
Change type of error check
1 parent 8908613 commit 3957d56

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/astro_image_display_api/widget_api_test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,11 +99,11 @@ def test_offset_by(self, data, wcs):
9999
self.image.offset_by(10 * u.arcmin, 10 * u.arcmin)
100100

101101
# A mix of pixel and sky should produce an error
102-
with pytest.raises(ValueError, match='but dy is of type'):
102+
with pytest.raises(u.UnitConversionError, match='are not convertible'):
103103
self.image.offset_by(10 * u.arcmin, 10)
104104

105105
# A mix of inconsistent units should produce an error
106-
with pytest.raises(u.UnitConversionError):
106+
with pytest.raises(u.UnitConversionError, match='are not convertible'):
107107
self.image.offset_by(1 * u.arcsec, 1 * u.AA)
108108

109109
def test_zoom_level(self, data):

0 commit comments

Comments
 (0)