Skip to content

Commit

Permalink
Merge pull request #375 from astrofrog/fix-tests
Browse files Browse the repository at this point in the history
Fix --remote-data tests
  • Loading branch information
astrofrog authored Jul 13, 2023
2 parents 00351ae + 1fc620b commit 1432cec
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/celestial.rst
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ coordinate falls within the bounds of the input image.)
As an example, we start off by opening a FITS file using Astropy::

>>> from astropy.io import fits
>>> hdu = fits.open('http://data.astropy.org/galactic_center/gc_msx_e.fits')[0] # doctest: +REMOTE_DATA
>>> hdu = fits.open('http://data.astropy.org/galactic_center/gc_msx_e.fits')[0] # doctest: +REMOTE_DATA +IGNORE_OUTPUT
Downloading http://data.astropy.org/galactic_center/gc_msx_e.fits [Done]

The image is currently using a Plate Carée projection::
Expand Down
Binary file not shown.
4 changes: 3 additions & 1 deletion reproject/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,9 @@ def parse_output_projection(output_projection, shape_in=None, shape_out=None, ou
"does not contain complete shape information"
)
elif isinstance(output_projection, (BaseLowLevelWCS, BaseHighLevelWCS)):
if isinstance(output_projection, BaseLowLevelWCS):
if isinstance(output_projection, BaseLowLevelWCS) and not isinstance(
output_projection, BaseHighLevelWCS
):
wcs_out = HighLevelWCSWrapper(output_projection)
else:
wcs_out = output_projection
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ passenv =
setenv =
HOME = {envtmpdir}
MPLBACKEND = Agg
PYTEST_COMMAND = pytest --arraydiff --arraydiff-default-format=fits --pyargs reproject --cov reproject --cov-config={toxinidir}/setup.cfg {toxinidir}/docs
PYTEST_COMMAND = pytest --arraydiff --arraydiff-default-format=fits --pyargs reproject --cov reproject --cov-config={toxinidir}/setup.cfg {toxinidir}/docs --remote-data
devdeps: PIP_EXTRA_INDEX_URL = https://pypi.anaconda.org/astropy/simple https://pypi.anaconda.org/scientific-python-nightly-wheels/simple
changedir =
.tmp/{envname}
Expand Down

0 comments on commit 1432cec

Please sign in to comment.