Skip to content

Commit 4338842

Browse files
authored
Ignore black formatting for b013 test case (#251)
* Ignore black formatting for b013 test case * Ack, needed to updated expected test result lineno
1 parent d4afd14 commit 4338842

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

Diff for: tests/b013.py

+4
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,15 @@
1111
# pointless use of tuple
1212
pass
1313

14+
# fmt: off
15+
# Turn off black to keep brackets around
16+
# single exception for testing purposes.
1417
try:
1518
pass
1619
except (ValueError):
1720
# not using a tuple means it's OK (if odd)
1821
pass
22+
# fmt: on
1923

2024
try:
2125
pass

Diff for: tests/test_bugbear.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def test_b013(self):
204204
bbc = BugBearChecker(filename=str(filename))
205205
errors = list(bbc.run())
206206
expected = self.errors(
207-
B013(10, 0, vars=("ValueError",)), B013(28, 0, vars=("re.error",))
207+
B013(10, 0, vars=("ValueError",)), B013(32, 0, vars=("re.error",))
208208
)
209209
self.assertEqual(errors, expected)
210210

0 commit comments

Comments
 (0)