Skip to content

Commit cdfa5fc

Browse files
committed
Adding regression test for null results
1 parent 2ce5af9 commit cdfa5fc

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import pytest
2+
3+
from astropy.table import Table
4+
5+
from astroquery import sha
6+
from astroquery.exceptions import NoResultsWarning
7+
8+
9+
@pytest.mark.remote_data
10+
def test_query_no_results():
11+
# Test for issue #1836
12+
with pytest.warns(NoResultsWarning):
13+
result = sha.query(ra=219.57741, dec=64.171525, size=0.001)
14+
15+
assert isinstance(result, Table)
16+
assert len(result) == 0

0 commit comments

Comments
 (0)