Skip to content

Commit

Permalink
add skip envs to tests module
Browse files Browse the repository at this point in the history
  • Loading branch information
vinicvaz committed Nov 23, 2023
1 parent e897c2f commit b99ba3d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/domino/testing/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
from .dry_run import piece_dry_run
from .dry_run import piece_dry_run
from .utils import skip_envs
6 changes: 6 additions & 0 deletions src/domino/testing/utils.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import os
import pytest

def skip_envs(*envs):
env = os.environ.get('DOMINO_TESTS_ENVIRONMENT')
return pytest.mark.skipif(env in list(envs),reason=f"Not suitable envrionment {env} for current test")

0 comments on commit b99ba3d

Please sign in to comment.