Skip to content

Commit 7dee5bf

Browse files
committed
Update CI workflows
Also update `tests` task in Pixi so by default doesnt run flaky tests
1 parent 7fb3c88 commit 7dee5bf

3 files changed

Lines changed: 4 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ jobs:
127127
name: Unittest report ${{ matrix.os }}-${{ matrix.pixi-environment }}
128128
path: ${{ env.COVERAGE_REPORT }}
129129
flaky-unit-test:
130-
name: "Falky unit tests: ${{ matrix.os }} | pixi run -e ${{ matrix.pixi-environment }} tests"
130+
name: "Falky unit tests: ${{ matrix.os }} | pixi run -e ${{ matrix.pixi-environment }} tests -m 'flaky'"
131131
runs-on: ${{ matrix.os }}-latest
132132
needs: [cache-pixi-lock]
133133
permissions:
@@ -165,7 +165,7 @@ jobs:
165165
- name: Unit test
166166
id: unit-test
167167
run: |
168-
pixi run -e ${{ matrix.pixi-environment }} tests -v -s --cov=parcels --cov-report=xml --html="${COVERAGE_REPORT}" --self-contained-html
168+
pixi run -e ${{ matrix.pixi-environment }} tests -m 'flaky' -v -s --cov=parcels --cov-report=xml --html="${COVERAGE_REPORT}" --self-contained-html
169169
# explicitly save the cache so it gets updated, also do this even if it fails.
170170
- name: Save cached hypothesis directory
171171
id: save-hypothesis-cache

pixi.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ pytest-html = "*"
7777
pytest-cov = "*"
7878

7979
[feature.test.tasks]
80-
tests = { cmd = "pytest", description = "Run the test suite." }
80+
tests = { cmd = "pytest -m 'not flaky'", description = "Run the test suite." }
8181
tests-notebooks = { cmd = "pytest --nbval-lax docs/user_guide/examples", description = "Run the user guide example notebooks as tests." }
8282

8383

tests/datasets/test_remote.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ def tmp_path_parcels_example_data(monkeypatch, tmp_path):
1111
return tmp_path
1212

1313

14+
@pytest.mark.flaky
1415
@pytest.mark.parametrize("url", [remote._ODIE.get_url(filename) for filename in remote._ODIE.registry.keys()])
1516
def test_pooch_registry_url_reponse(url):
1617
response = requests.head(url)

0 commit comments

Comments
 (0)