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

Skip ISH tests if the root pages unreachable #202

Merged
merged 4 commits into from
Oct 7, 2024
Merged
Show file tree
Hide file tree
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: 3 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,15 @@ jobs:
create-args: >-
python=${{ matrix.python-version }}
attrs=22.2.0
aioitertools=0.11.0

- name: Test with pytest
run: pytest -n auto -v -W "ignore:Downloading test file:UserWarning::"
run: pytest -n auto -v -rsx -W "ignore:Downloading test file:UserWarning::"

- name: Test with pytspack installed
run: |
pip install https://github.com/noaa-oar-arl/pytspack/archive/master.zip
pytest -n auto -v -k with_pytspack
pytest -n auto -v -rsx -k with_pytspack

docs:
name: Check docs build
Expand Down
7 changes: 7 additions & 0 deletions tests/test_ish.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@

from monetio import ish

try:
import requests

requests.head("https://www1.ncdc.noaa.gov/pub/data/noaa/")
except Exception:
pytest.skip("NCEI server issues", allow_module_level=True)


def test_ish_read_history():
dates = pd.date_range("2020-09-01", "2020-09-02")
Expand Down
7 changes: 7 additions & 0 deletions tests/test_ish_lite.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@

from monetio import ish_lite

try:
import requests

r = requests.head("https://www1.ncdc.noaa.gov/pub/data/noaa/isd-lite/")
except Exception:
pytest.skip("NCEI server issues", allow_module_level=True)


def test_ish_read_history():
dates = pd.date_range("2020-09-01", "2020-09-02")
Expand Down