Skip to content

Commit aa5f3b6

Browse files
author
Lukas Burgey
committed
Add coverage badge
1 parent 10593a3 commit aa5f3b6

File tree

7 files changed

+22
-18
lines changed

7 files changed

+22
-18
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,8 @@ jobs:
2121
python -m pip install tox tox-gh-actions
2222
- run: tox
2323
name: Linting and testing with tox
24+
- name: Store coverage badge
25+
uses: actions/upload-artifact@v2
26+
with:
27+
name: coverage.svg
28+
path: coverage.svg

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,3 +110,4 @@ test-tokens.sh
110110
.vimspector.json
111111
install_certs.sh
112112
test.py
113+
coverage.svg

Makefile

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,9 @@ dist: clean
1010
upload: dist
1111
twine upload $(TWINE_ARGS) dist/*
1212

13-
.PHONY: coverage
14-
coverage:
15-
pytest --cov=flaat --cov-report=term-missing --show-capture=log
16-
1713
.PHONY: test
1814
test:
19-
pytest --show-capture=log --log-cli-level=debug
15+
tox -e py310
2016

2117
.PHONY: clean
2218
clean:
@@ -31,3 +27,4 @@ clean:
3127
@rm -f .coverage.*
3228
@rm -f ChangeLog
3329
@rm -f AUTHORS
30+
@rm -f coverage.svg

pyproject.toml

Lines changed: 0 additions & 3 deletions
This file was deleted.

pytest.ini

Lines changed: 0 additions & 6 deletions
This file was deleted.

setup.cfg

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ author-email = [email protected]
1010
home-page = https://github.com/indigo-dc/flaat
1111
project_urls =
1212
Bug Tracker = https://github.com/indigo-dc/flaat/issues
13-
Documentation = https://github.com/indigo-dc/flaat/blob/master/README.md
13+
Documentation = https://flaat.readthedocs.io/en/latest/
1414

1515
license = MIT
1616
license_file = LICENSE
@@ -49,4 +49,3 @@ aiohttp =
4949
aiohttp
5050
fastapi =
5151
fastapi>=0.61.2
52-

tox.ini

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@ python =
1010
3.9: py39
1111
3.10: py310, pylint, black, pyright
1212

13+
[pytest]
14+
addopts = --show-capture=log --log-cli-level=error
15+
asyncio_mode = auto
16+
# liboidcagent uses future.standard_library
17+
filterwarnings =
18+
ignore::DeprecationWarning:future.*:
19+
1320
[base]
1421
deps =
1522
-r requirements.txt
@@ -26,8 +33,12 @@ passenv =
2633
NON_JWT_*
2734

2835
[testenv:py310]
29-
deps = {[base]deps}
30-
commands = pytest --cov={[base]module} --cov-report=term-missing
36+
deps =
37+
{[base]deps}
38+
coverage-badge
39+
commands =
40+
pytest --cov={[base]module} --cov-report=term-missing:skip-covered
41+
coverage-badge -f -o coverage.svg
3142

3243
[testenv:pylint]
3344
deps =

0 commit comments

Comments
 (0)