astropy / pytest-remotedata

Pytest plugin to control whether tests are run that have remote data
BSD 3-Clause "New" or "Revised" License
23 stars 15 forks source link

Add a decorator for tests that should run only when no connection is available #3

Closed drdavella closed 7 years ago

drdavella commented 7 years ago

This will allow for code paths to be tested that expect remote data access to be disabled. Previously some tests in astropy tried to provide for this by accessing the INTERNET_OFF global variable, but this is no longer directly available to test code since it lives inside of this plugin.

astrofrog commented 7 years ago

Sounds good! Maybe an @internet_off decorator?