-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update plotting method testing. (#14)
- Loading branch information
1 parent
f26c198
commit 2a35ae8
Showing
2 changed files
with
13 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,18 @@ | ||
import healpy as hp | ||
from hipscat.catalog import Catalog | ||
from hipscat.inspection import plot_pixels, plot_points | ||
|
||
# pylint: disable=no-member | ||
|
||
def test_generate_map_order1(small_sky_dir_cloud, example_cloud_storage_options): | ||
|
||
def test_generate_map_order1(small_sky_dir_cloud, example_cloud_storage_options, mocker): | ||
"""Basic test that map data can be generated (does not test that a plot is rendered)""" | ||
cat = Catalog.read_from_hipscat(small_sky_dir_cloud, storage_options=example_cloud_storage_options) | ||
plot_pixels(cat, draw_map=False) | ||
plot_points(cat, draw_map=False) | ||
|
||
mocker.patch("healpy.mollview") | ||
plot_pixels(cat) | ||
hp.mollview.assert_called_once() | ||
|
||
hp.mollview.reset_mock() | ||
plot_points(cat) | ||
hp.mollview.assert_called_once() |