Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix visual tests #2501

Merged
merged 2 commits into from
Jul 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions glue/tests/visual/py311-test-visual.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"glue.viewers.histogram.tests.test_viewer.test_simple_viewer": "cb08123fbad135ab614bb7ec13475fcc83321057d884fe80c3a32970b2d14762",
"glue.viewers.image.tests.test_viewer.test_simple_viewer": "72abd60b484d14f721254f027bb0ab9b36245d5db77eb87693f4dd9998fd28be",
"glue.viewers.image.tests.test_viewer.test_region_layer": "0114922ab0a3980f56252656c69545927841aea0e6950250cdc2b1bafcd19d50",
"glue.viewers.image.tests.test_viewer.test_region_layer_flip": "a142142f34961aba7e98188ad43abafe0e6e5b82e13e8cdab5131d297ed5832c",
"glue.viewers.profile.tests.test_viewer.test_simple_viewer": "f68a21be5080fec513388b2d2b220512e7b0df5498e2489da54e58708de435b3",
"glue.viewers.scatter.tests.test_viewer.test_simple_viewer": "1020a7bd3abe40510b9e03047c3b423b75c3c64ac18e6dcd6257173cec1ed53f",
"glue.viewers.histogram.tests.test_viewer.test_simple_histogram_viewer": "cb08123fbad135ab614bb7ec13475fcc83321057d884fe80c3a32970b2d14762",
"glue.viewers.image.tests.test_viewer.test_simple_image_viewer": "72abd60b484d14f721254f027bb0ab9b36245d5db77eb87693f4dd9998fd28be",
"glue.viewers.image.tests.test_viewer.test_image_region_layer": "0114922ab0a3980f56252656c69545927841aea0e6950250cdc2b1bafcd19d50",
"glue.viewers.image.tests.test_viewer.test_image_region_layer_flip": "a142142f34961aba7e98188ad43abafe0e6e5b82e13e8cdab5131d297ed5832c",
"glue.viewers.profile.tests.test_viewer.test_simple_profile_viewer": "f68a21be5080fec513388b2d2b220512e7b0df5498e2489da54e58708de435b3",
"glue.viewers.scatter.tests.test_viewer.test_simple_scatter_viewer": "1020a7bd3abe40510b9e03047c3b423b75c3c64ac18e6dcd6257173cec1ed53f",
"glue.viewers.scatter.tests.test_viewer.test_scatter_density_map": "3379d655262769a6ccbdbaf1970bffa9237adbec23a93d3ab75da51b9a3e7f8b",
"glue.viewers.image.tests.test_viewer.TestWCSRegionDisplay.test_wcs_viewer": "651e0d954c6b77becb7064de24f5101b9f2882adabc1d5aedbc183b9762c59b1",
"glue.viewers.image.tests.test_viewer.TestWCSRegionDisplay.test_flipped_wcs_viewer": "fcc18a1398d1f3f61b6989a722402cde9365a34483eedf8eac222647e20eb8ab"
"glue.viewers.image.tests.test_viewer.TestWCSRegionDisplay.test_image_wcs_viewer": "651e0d954c6b77becb7064de24f5101b9f2882adabc1d5aedbc183b9762c59b1",
"glue.viewers.image.tests.test_viewer.TestWCSRegionDisplay.test_image_flipped_wcs_viewer": "fcc18a1398d1f3f61b6989a722402cde9365a34483eedf8eac222647e20eb8ab"
}
2 changes: 1 addition & 1 deletion glue/viewers/histogram/tests/test_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


@visual_test
def test_simple_viewer():
def test_simple_histogram_viewer():

# Make sure the simple viewer can be instantiated

Expand Down
10 changes: 5 additions & 5 deletions glue/viewers/image/tests/test_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@


@visual_test
def test_simple_viewer():
def test_simple_image_viewer():

# Make sure the simple viewer can be instantiated

Expand All @@ -35,7 +35,7 @@ def test_simple_viewer():


@visual_test
def test_region_layer():
def test_image_region_layer():
poly_1 = Polygon([(20, 20), (60, 20), (60, 40), (20, 40)])
poly_2 = Polygon([(60, 50), (60, 70), (80, 70), (80, 50)])
poly_3 = Polygon([(10, 10), (15, 10), (15, 15), (10, 15)])
Expand Down Expand Up @@ -123,7 +123,7 @@ def test_region_layer_logic():


@visual_test
def test_region_layer_flip():
def test_image_region_layer_flip():
poly_1 = Polygon([(20, 20), (60, 20), (60, 40), (20, 40)])
poly_2 = Polygon([(60, 50), (60, 70), (80, 70), (80, 50)])
poly_3 = Polygon([(10, 10), (15, 10), (15, 15), (10, 15)])
Expand Down Expand Up @@ -218,7 +218,7 @@ def test_wcs_viewer_good_link(self):
assert self.viewer.layers[1].enabled

@visual_test
def test_wcs_viewer(self):
def test_image_wcs_viewer(self):
self.viewer.add_data(self.image1)

link1 = LinkSame(self.region_data.center_x_id, self.image1.world_component_ids[1])
Expand All @@ -237,7 +237,7 @@ def test_wcs_viewer(self):
return self.viewer.figure

@visual_test
def test_flipped_wcs_viewer(self):
def test_image_flipped_wcs_viewer(self):
self.viewer.add_data(self.image1)

link1 = LinkSame(self.region_data.center_x_id, self.image1.world_component_ids[1])
Expand Down
2 changes: 1 addition & 1 deletion glue/viewers/profile/tests/test_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@


@visual_test
def test_simple_viewer():
def test_simple_profile_viewer():

# Make sure the simple viewer can be instantiated

Expand Down
2 changes: 1 addition & 1 deletion glue/viewers/scatter/tests/test_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@


@visual_test
def test_simple_viewer():
def test_simple_scatter_viewer():

# Make sure the simple viewer can be instantiated

Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ passenv =
HOME
setenv =
dev: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple https://pypi.anaconda.org/liberfa/simple https://pypi.anaconda.org/scientific-python-nightly-wheels/simple
visual: MPLFLAGS = -m "mpl_image_compare" --mpl --mpl-generate-summary=html --mpl-results-path={toxinidir}/results --mpl-hash-library={toxinidir}/glue/tests/visual/{envname}.json --mpl-baseline-path=https://raw.githubusercontent.com/glue-viz/glue-core-visual-tests/images/{envname}/
visual: MPLFLAGS = -m "mpl_image_compare" --mpl --mpl-generate-summary=html --mpl-results-path={toxinidir}/results --mpl-hash-library={toxinidir}/glue/tests/visual/{envname}.json --mpl-baseline-path=https://raw.githubusercontent.com/glue-viz/glue-core-visual-tests/main/images/{envname}/
whitelist_externals =
find
rm
Expand Down