Skip to content

Commit

Permalink
test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
kecnry committed Dec 1, 2023
1 parent 8e7890f commit 9ef3691
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions jdaviz/configs/imviz/tests/test_links_control.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,13 @@ def test_plugin(self):

assert lc_plugin.need_clear_markers is False
lc_plugin.link_type.selected = 'WCS'

def test_user_api(self):
lc_plugin = self.imviz.plugins['Links Control']
assert lc_plugin.link_type == 'Pixels'
# wcs_use_affine is inapplicable when link_type == 'Pixels'
with pytest.raises(AttributeError):
lc_plugin.wcs_use_affine

lc_plugin.link_type = 'WCS'
assert lc_plugin.wcs_use_affine is True

0 comments on commit 9ef3691

Please sign in to comment.