Skip to content

Commit

Permalink
Don't auto download IERS during testing
Browse files Browse the repository at this point in the history
  • Loading branch information
dstansby committed May 6, 2022
1 parent 2c2676a commit 09d7d28
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions sunpy/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@

import astropy
import astropy.config.paths
import astropy.io.fits
from astropy.utils import iers

from sunpy.util import SunpyUserWarning

Expand Down Expand Up @@ -39,6 +41,17 @@ def jsoc_test_email():
return "nabil.freij@gmail.com"


@pytest.fixture(scope='session', autouse=True)
def no_download_iers(request):
# Don't try and download IERS during tests
# See https://github.com/astropy/astropy/issues/12998 for issue that this
# sidesteps
old_value = iers.conf.auto_download
iers.conf.auto_download = False
yield
iers.conf.auto_download = old_value


@pytest.fixture(scope='session', autouse=True)
def tmp_config_dir(request):
"""
Expand Down

0 comments on commit 09d7d28

Please sign in to comment.