forked from dcos/dcos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
conftest.py
33 lines (23 loc) · 1.03 KB
/
conftest.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import os
import pytest
import release
@pytest.fixture
def release_config():
if not os.path.exists('dcos-release.config.yaml'):
pytest.skip("Skipping because there is no configuration in dcos-release.config.yaml")
return release.load_config('dcos-release.config.yaml')
@pytest.fixture
def release_config_testing(release_config):
if 'testing' not in release_config:
pytest.skip("Skipped because there is no `testing` configuration in dcos-release.config.yaml")
return release_config['testing']
@pytest.fixture
def release_config_aws(release_config_testing):
if 'aws' not in release_config_testing:
pytest.skip("Skipped because there is no `testing.aws` configuration in dcos-release.config.yaml")
return release_config_testing['aws']
@pytest.fixture
def release_config_azure(release_config_testing):
if 'azure' not in release_config_testing:
pytest.skip("Skipped because there is no `testing.azure` configuration in dcos-release.config.yaml")
return release_config_testing['azure']