Skip to content
This repository was archived by the owner on Oct 16, 2025. It is now read-only.

Commit 5cd69d6

Browse files
authored
🧪 TESTS: fix issue with test coverage (#1)
1 parent a83ba37 commit 5cd69d6

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

‎.github/workflows/tests.yml‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,11 @@ jobs:
3636
python-version: ${{ matrix.python-version }}
3737

3838
- name: Installation (deps and package)
39+
# we install with flit --pth-file,
40+
# so that coverage will be recorded up for the module
3941
run: |
40-
pip install .[testing]
42+
pip install flit
43+
flit install --deps=production --extras=test --pth-file
4144
4245
- name: Run pytest
4346
run: |

‎pyproject.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ requires-python=">=3.6"
2020
requires=["mdformat~=0.3.1"]
2121

2222
[tool.flit.metadata.requires-extra]
23-
testing = [
23+
test = [
2424
"pytest~=6.0",
2525
"coverage",
2626
"pytest-cov",

‎tox.ini‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ envlist = py{36,37,38}
33
isolated_build = True
44

55
[testenv:py{36,37,38}]
6-
extras = testing
7-
commands = pytest {posargs}
6+
extras = test
7+
commands = pytest --cov={envsitepackagesdir}/mdformat_tables {posargs}
88

99
[testenv:py{36,37,38}-pre-commit]
1010
deps = pre-commit

0 commit comments

Comments
 (0)