Skip to content

Commit

Permalink
Fix coverage/import errors in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gpauloski committed Oct 31, 2024
1 parent 4d285e9 commit 8e5e2cf
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 8 deletions.
27 changes: 20 additions & 7 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ dependencies = [
"matplotlib",
"numpy",
"pandas",
"parsl",
"proxystore",
"scipy",
"scikit-learn",
Expand Down Expand Up @@ -73,17 +74,29 @@ docs = [
"mkdocstrings-python",
]

[tool.mypy]
plugins = [
"numpy.typing.mypy_plugin"
[tool.coverage.report]
show_missing = true
skip_covered = true
exclude_also = [
# a more strict default pragma
"\\# pragma: no cover\\b",
# allow defensive code
"^\\s*raise AssertionError\\b",
"^\\s*raise NotImplementedError\\b",
"^\\s*return NotImplemented\\b",
"^\\s*raise$",
# typing-related code
"^\\s*if (False|TYPE_CHECKING):",
": \\.\\.\\.(\\s*#.*)?$",
"^ +\\.\\.\\.$",
]

[tool.pytest.ini_options]
addopts = [
"--import-mode=importlib",
[tool.mypy]
plugins = [
"numpy.typing.mypy_plugin",
"proxystore.mypy_plugin",
]


[tool.setuptools.packages.find]
include = ["flight*"]
namespaces = false
Empty file.
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ allowlist_externals = coverage
commands =
coverage erase
coverage run -m pytest tests {posargs}
coverage report
coverage report --ignore-errors

[testenv:pre-commit]
skip_install = true
Expand Down

0 comments on commit 8e5e2cf

Please sign in to comment.