Skip to content

Commit 110ae32

Browse files
committed
try skipping the test if it recognizes gh actions env var
1 parent ea3647d commit 110ae32

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

.github/workflows/unit_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
2929
- name: Test with pytest and coverage
3030
run: |
31-
pytest ./tests/unit_tests --cov=datacrunch
31+
pytest --cov=datacrunch
3232
3333
- name: 'Upload coverage to Codecov'
3434
uses: codecov/codecov-action@v1

tests/integration_tests/test_volumes.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1+
import os
12
import pytest
23
from datacrunch.datacrunch import DataCrunchClient
34

5+
IN_GITHUB_ACTIONS = os.getenv("GITHUB_ACTIONS") == "true"
46

7+
8+
@pytest.mark.skipif(IN_GITHUB_ACTIONS, reason="Test doesn't work in Github Actions.")
59
@pytest.mark.withoutresponses
610
class TestVolumes():
711

0 commit comments

Comments
 (0)