From 5487538d26c2e0fd254043de6eece88551bdfd71 Mon Sep 17 00:00:00 2001 From: liamhuber Date: Mon, 6 Jan 2025 13:21:42 -0800 Subject: [PATCH] Black check and ignore docs --- pyproject.toml | 9 ++++++++- setup.py | 2 +- tests/benchmark/__init__.py | 2 +- tests/integration/__init__.py | 2 +- tests/integration/test_readme.py | 2 +- tests/unit/__init__.py | 2 +- tests/unit/test_tests.py | 2 +- 7 files changed, 14 insertions(+), 7 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 784ca41..a99297e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,4 +73,11 @@ select = [ ignore = ["E501"] #ignore line-length violations [tool.ruff.lint.per-file-ignores] -"__init__.py" = ["F401"] # Ignore unused imports in init files -- we specify APIs this way \ No newline at end of file +"__init__.py" = ["F401"] # Ignore unused imports in init files -- we specify APIs this way + +[tool.black] +extend-exclude = ''' +( + ^/docs +) +''' \ No newline at end of file diff --git a/setup.py b/setup.py index edb08a3..fcbb31f 100644 --- a/setup.py +++ b/setup.py @@ -5,4 +5,4 @@ setup( version=versioneer.get_version(), cmdclass=versioneer.get_cmdclass(), -) \ No newline at end of file +) diff --git a/tests/benchmark/__init__.py b/tests/benchmark/__init__.py index 102f047..1a40b4b 100644 --- a/tests/benchmark/__init__.py +++ b/tests/benchmark/__init__.py @@ -1,3 +1,3 @@ """ Timed tests to make sure critical components stay sufficiently efficient. -""" \ No newline at end of file +""" diff --git a/tests/integration/__init__.py b/tests/integration/__init__.py index 85f3594..7d4976e 100644 --- a/tests/integration/__init__.py +++ b/tests/integration/__init__.py @@ -1,3 +1,3 @@ """ Large and potentially slower tests to check how the pieces fit together. -""" \ No newline at end of file +""" diff --git a/tests/integration/test_readme.py b/tests/integration/test_readme.py index 443de9b..579562d 100644 --- a/tests/integration/test_readme.py +++ b/tests/integration/test_readme.py @@ -16,5 +16,5 @@ def test_void(self): pass -if __name__ == '__main__': +if __name__ == "__main__": unittest.main() diff --git a/tests/unit/__init__.py b/tests/unit/__init__.py index cc7dda6..250330c 100644 --- a/tests/unit/__init__.py +++ b/tests/unit/__init__.py @@ -1,3 +1,3 @@ """ Small tests run, relatively fast tests for checking individual bits of the code base. -""" \ No newline at end of file +""" diff --git a/tests/unit/test_tests.py b/tests/unit/test_tests.py index f0baf98..3b4d027 100644 --- a/tests/unit/test_tests.py +++ b/tests/unit/test_tests.py @@ -7,4 +7,4 @@ class TestVersion(unittest.TestCase): def test_version(self): version = pyiron_module_template.__version__ print(version) - self.assertTrue(version.startswith('0')) + self.assertTrue(version.startswith("0"))