Skip to content
This repository was archived by the owner on Mar 19, 2024. It is now read-only.

Commit a49f12e

Browse files
committed
pytest and pytest-coverage fixes
- updated pytest.ini, setup.cfg, and .coveragerc - moved .coveragerc to project root folder since make calls my tests - pinned pytest-cov==2.5.1 to address pytest-dev/pytest-cov#306 - updated makefile to properly run make test and make coverage - updated .drone.yml to run coverage during builds and not run un-needed make depoyment
1 parent ce92832 commit a49f12e

File tree

5 files changed

+55
-21
lines changed

5 files changed

+55
-21
lines changed

cli/.coveragerc renamed to .coveragerc

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,3 @@ omit =
88
setup.py
99
scratch*.py
1010

11-
[html]
12-
directory=./htmlcov
13-

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,13 @@ lint:
6767
pylint $(PROJ_SLUG)
6868

6969
smoketest:
70-
pytest --rootdir=cli --cov-config=cli/.coveragerc -k "smoke" -vv cli/tests
70+
pytest --rootdir=cli -k "smoke" -vv cli/tests
7171

7272
test:
7373
pytest --rootdir=cli cli/tests
7474

7575
coverage:
76-
pytest --rootdir=cli --cov-config=cli/.coveragerc -vv cli/tests
76+
pytest --rootdir=cli --cov=cli --cov-config=.coveragerc cli/tests
7777

7878
clean:
7979
rm -rf cli/dist \

cli/pytest.ini

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,15 @@
11
[pytest]
22
filterwarnings =
33
ignore::DeprecationWarning
4-
ignore::UserWarning
4+
ignore::UserWarning
5+
6+
testpaths = tests
7+
8+
[run]
9+
omit =
10+
*/venv/*
11+
*/tests/*
12+
*/docs/*
13+
*/dist/*
14+
setup.py
15+
scratch*.py

cli/requirements.txt

Lines changed: 41 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,43 @@
1-
boto3==1.9.139
1+
altgraph==0.16.1
2+
astroid==2.2.5
3+
atomicwrites==1.3.0
4+
attrs==19.1.0
5+
boto3==1.9.200
6+
botocore==1.12.200
7+
Click==7.0
28
configparser==3.7.4
3-
flake8==3.7.7
9+
coverage==4.5.4
10+
docutils==0.14
11+
entrypoints==0.3
12+
flake8==3.7.8
13+
importlib-metadata==0.19
14+
isort==4.3.21
15+
jmespath==0.9.4
16+
lazy-object-proxy==1.4.1
17+
macholib==1.11
18+
mccabe==0.6.1
19+
more-itertools==7.2.0
20+
packaging==19.1
421
pipdeptree==0.13.2
5-
PyInstaller==3.4
6-
pytest-cov==2.6.1
7-
python-dotenv==0.10.1
8-
PyYAML==5.1
9-
ruamel.yaml==0.15.94
10-
wheel==0.33.1
11-
pylint
12-
pytest
13-
pytest-mock
22+
pluggy==0.12.0
23+
py==1.8.0
24+
pycodestyle==2.5.0
25+
pyflakes==2.1.1
26+
PyInstaller==3.5
27+
pylint==2.3.1
28+
pyparsing==2.4.2
29+
pytest==5.0.1
30+
pytest-cov==2.5.1
31+
pytest-mock==1.10.4
32+
python-dateutil==2.8.0
33+
python-dotenv==0.10.3
34+
PyYAML==5.1.2
35+
ruamel.yaml==0.16.0
36+
ruamel.yaml.clib==0.1.0
37+
s3transfer==0.2.1
38+
six==1.12.0
39+
typed-ast==1.4.0
40+
urllib3==1.25.3
41+
wcwidth==0.1.7
42+
wrapt==1.11.2
43+
zipp==0.5.2

cli/setup.cfg

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,2 @@
11
[flake8]
22
max-line-length = 99
3-
4-
[tool:pytest]
5-
addopts = --cov=cli -vv
6-
testpaths = tests

0 commit comments

Comments
 (0)