File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -84,8 +84,6 @@ ignore = [
8484 " SIM905" , # Consider using a list literal instead of `str.split`
8585 " UP030" , # Use implicit references for positional format fields
8686 " UP006" , # Use `list` instead of `List` for type annotation
87- " B009" , # Do not call `getattr` with a constant attribute value. It is not any safer than normal property access.
88- " B010" , # Do not call `setattr` with a constant attribute value. It is not any safer than normal property access.
8987 " RUF059" , # Unpacked variable `matches` is never used
9088 " SIM102" , # Use a single `if` statement instead of nested `if` statements
9189 " FA100" , # Add `from __future__ import annotations` to simplify `typing.Optional`
Original file line number Diff line number Diff line change @@ -642,8 +642,8 @@ def test_max_n(run):
642642def test_quiet_is_quiet ():
643643 captured_standard_output = StringIO ()
644644 captured_standard_error = StringIO ()
645- setattr ( captured_standard_output , " buffer" , BytesIO () )
646- setattr ( captured_standard_error , " buffer" , BytesIO () )
645+ captured_standard_output . buffer = BytesIO ()
646+ captured_standard_error . buffer = BytesIO ()
647647 old_stdout = sys .stdout
648648 old_stderr = sys .stderr
649649 try :
@@ -655,8 +655,8 @@ def test_quiet_is_quiet():
655655 sys .stderr = old_stderr
656656 assert captured_standard_output .getvalue () == ""
657657 assert captured_standard_error .getvalue () == ""
658- assert getattr ( captured_standard_output , " buffer" ) .getvalue () == b""
659- assert getattr ( captured_standard_output , " buffer" ) .getvalue () == b""
658+ assert captured_standard_output . buffer .getvalue () == b""
659+ assert captured_standard_output . buffer .getvalue () == b""
660660
661661
662662def test_x_brace_notation ():
You can’t perform that action at this time.
0 commit comments