diff --git a/pyproject.toml b/pyproject.toml index 7536cf7..deb1a84 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,5 +62,10 @@ required-imports = [ "from __future__ import annotations", ] +[tool.ruff.lint.extend-per-file-ignores] +"tests/**/*.py" = [ + "S101", # asserts allowed in tests... +] + [tool.coverage.report] include = ["python_template/*"] # Please revise this line. diff --git a/python_template/__init__.py b/python_template/__init__.py index 35fd67a..46621c9 100644 --- a/python_template/__init__.py +++ b/python_template/__init__.py @@ -5,3 +5,7 @@ from ._version import __version__ __email__ = "jinzhe.zeng@rutgers.edu" + +__all__ = [ + "__version__", +] \ No newline at end of file diff --git a/tests/test_version.py b/tests/test_version.py index cb5e2a1..89e2dc4 100644 --- a/tests/test_version.py +++ b/tests/test_version.py @@ -1,3 +1,4 @@ +"""Test version.""" from __future__ import annotations from importlib.metadata import version @@ -5,5 +6,6 @@ from python_template import __version__ -def test_version(): +def test_version() -> NoReturn: + """Test version.""" assert version("python-template") == __version__