-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtox.ini
109 lines (96 loc) · 2.41 KB
/
tox.ini
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
[coverage:run]
omit = .tox/*
[pytest]
addopts = --cov=bert_e --cov-report=term --cov-report=xml
testpaths = bert_e/tests
[testenv]
basepython = python3
deps = -r{toxinidir}/requirements.txt
[testenv:flake8]
deps =
flake8==4.0.1
pip==22.3.1
commands = flake8 bert_e/
[testenv:utests]
deps =
pip==22.3.1
pytest-cov==5.0.0
commands = pytest bert_e/tests/unit/ {posargs}
[testenv:tests-api-mock]
deps =
pip==22.3.1
pytest-cov==5.0.0
commands = pytest -v -k mock bert_e/tests/test_git_host.py {posargs}
[testenv:tests-server]
deps =
pip==22.3.1
pytest-cov==5.0.0
commands = pytest bert_e/tests/test_server.py {posargs}
[testenv:tests-noqueue]
deps =
pip==22.3.1
passenv = CI
commands =
coverage run -am bert_e.tests.test_bert_e \
-v \
--git-host mock \
--repo-prefix _test_bert_e_eve \
--disable-queues \
scality_berte_test \
berte_e_test \
bert_e_password \
bert_e_test_user \
bert_e_password \
bert_e_test_admin \
bert_e_password \
{posargs}
[testenv:tests]
deps =
pip==22.3.1
passenv = CI
commands =
coverage run -am bert_e.tests.test_bert_e \
-v \
--git-host mock \
--repo-prefix _test_bert_e_eve \
scality_berte_test \
berte_e_test \
bert_e_password \
bert_e_test_user \
bert_e_password \
bert_e_test_admin \
bert_e_password \
{posargs}
[testenv:coverage-report]
deps =
pip==22.3.1
commands =
coverage report
coverage html
[testenv:run]
passenv =
BERT_E_*
WEBHOOK_*
setenv =
BERT_E_CLIENT_SECRET = {env:BERT_E_CLIENT_SECRET:'bert_e_client_secret'}
BERT_E_CLIENT_ID = {env:BERT_E_CLIENT_ID:'bert_e_client_id'}
BERT_E_ROBOT_PASSWORD = {env:GITHUB_TOKEN}
BERT_E_JIRA_TOKEN = {env:BERT_E_JIRA_TOKEN:'jira_token'}
WEBHOOK_LOGIN = {env:WEBHOOK_LOGIN:'webhook'}
WEBHOOK_PWD = {env:WEBHOOK_PWD:'webhook'}
commands = bert-e-serve -v -f {env:BERT_E_SETTINGS:'settings.yml'} -p 8000
[testenv:tests-githost]
passenv = BERT_E_*
commands =
coverage run -am bert_e.tests.test_bert_e \
-v \
--git-host {env:BERT_E_GITHOST:'git_host'} \
--repo-prefix {env:BERT_E_REPO_PREFIX:'_test_bert_e_eve'} \
{env:BERT_E_GITHOST_TEAM:'team_name'} \
{env:BERT_E_ROBOT_USERNAME:'robot_username'} \
{env:BERT_E_ROBOT_PASSWORD:'robot_password'} \
{env:BERT_E_CONTRIBUTOR_USERNAME:'contributor_username'} \
{env:BERT_E_CONTRIBUTOR_PASSWORD:'contributor_password'} \
{env:BERT_E_ADMIN_USERNAME:'admin_username'} \
{env:BERT_E_ADMIN_PASSWORD:'admin_password'} \
{posargs}