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

alfalfa: add some tests to increase test coverage from 95 to 100 percent #2886

Merged
merged 2 commits into from
Dec 8, 2023
Merged
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
5 changes: 5 additions & 0 deletions astroquery/alfalfa/tests/test_alfalfa.py
Original file line number Diff line number Diff line change
@@ -63,6 +63,7 @@ def data_path(filename):

# Test Case: A Seyfert 1 galaxy
coords = coordinates.SkyCoord('0h8m05.63s +14d50m23.3s')
coordsOC = coordinates.SkyCoord(0.59583, 27.21056, unit='deg')

ALFALFA = alfalfa.core.Alfalfa()

@@ -75,3 +76,7 @@ def test_alfalfa_catalog(patch_get, patch_get_readable_fileobj, coords=coords):
def test_alfalfa_crossID(patch_get, patch_get_readable_fileobj, coords=coords):
agc = ALFALFA.query_region(coords, optical_counterpart=True)
assert agc == 100051
agc = ALFALFA.query_region(coordsOC, optical_counterpart=False)
assert agc == 12920
agc = ALFALFA.query_region(coordsOC, optical_counterpart=False, radius='0 arcmin')
assert agc is None