Skip to content

Commit c8b3af9

Browse files
Add test and changelog
1 parent afbbf17 commit c8b3af9

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

doc/whatsnew/fragments/9145.bugfix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Restore "errors / warnings by module" section to report output (with `-ry`).
2+
3+
Closes #9145

tests/test_self.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -981,6 +981,11 @@ def test_can_list_directories_without_dunder_init(tmp_path: Path) -> None:
981981
stderr=subprocess.PIPE,
982982
)
983983

984+
def test_warnings_by_module(self) -> None:
985+
path = join(HERE, "regrtest_data", "unused_variable.py")
986+
expected = "errors / warnings by module"
987+
self._test_output([path, "-ry"], expected_output=expected)
988+
984989
@pytest.mark.needs_two_cores
985990
def test_jobs_score(self) -> None:
986991
path = join(HERE, "regrtest_data", "unused_variable.py")

0 commit comments

Comments
 (0)