Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
blablatdinov committed May 31, 2024
1 parent e6d0a35 commit a3758ac
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 0 additions & 1 deletion ondivi/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ def define_changed_lines(diff: DiffStr) -> dict[FileNameStr, list[int]]:
current_file = ''
for line in diff.splitlines():
if _line_contain_filename(line):
# assert False, line.split(' b/')
current_file = line.split(' b/')[-1].strip()
res[current_file] = []
elif _diff_line_contain_changed_lines(line):
Expand Down
5 changes: 5 additions & 0 deletions tests/unit/test_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ def test_controller() -> None:


def test_without_violation() -> None:
"""Test filtering without violations."""
violations, found = filter_out_violations(
{},
['All checks passed'],
Expand All @@ -95,6 +96,10 @@ def test_without_violation() -> None:


def test_define_filename() -> None:
"""Test define filename.
Created for kill mutant
"""
got = define_changed_lines(
'diff --git XX b/ XX b/ file.py',
)
Expand Down

0 comments on commit a3758ac

Please sign in to comment.