Skip to content

Commit 20c72b9

Browse files
author
Martin Møldrup
committed
Fix linting issues
1 parent ae72d6a commit 20c72b9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

snappylapy/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# ruff: noqa: I001, E402
12
"""Define the public api for the snappylapy package."""
23
import pytest
34
pytest.register_assert_rewrite("snappylapy.expectation_classes.base_snapshot")

snappylapy/_cli.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,12 @@ def init() -> None:
3636
typer.echo(f"Added {constants.TEST_RESULTS_DIR_NAME}/ to .gitignore.")
3737

3838

39-
4039
@app.command()
4140
def clear() -> None:
4241
"""Clear all test results and snapshots, recursively, using pathlib."""
4342
list_of_files_to_delete: list[pathlib.Path] = []
4443
for dir_name in [constants.TEST_RESULTS_DIR_NAME, constants.SNAPSHOT_DIR_NAME]:
45-
for root_dir in pathlib.Path(".").rglob(dir_name):
44+
for root_dir in pathlib.Path().rglob(dir_name):
4645
for file in root_dir.iterdir():
4746
if file.is_file():
4847
list_of_files_to_delete.append(file)
@@ -61,7 +60,7 @@ def clear() -> None:
6160
file.unlink()
6261
# Delete directories
6362
for dir_name in [constants.TEST_RESULTS_DIR_NAME, constants.SNAPSHOT_DIR_NAME]:
64-
for root_dir in pathlib.Path(".").rglob(dir_name):
63+
for root_dir in pathlib.Path().rglob(dir_name):
6564
root_dir.rmdir()
6665
typer.echo(f"Deleted {len(list_of_files_to_delete)} files.")
6766

0 commit comments

Comments
 (0)