Skip to content

Commit 0120351

Browse files
Fix trailing whitespace and blanket type-ignore
Signed-off-by: Bernhard Kaindl <[email protected]>
1 parent c018c68 commit 0120351

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

pytest.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,4 @@ log_cli_level=INFO
2727
#
2828
# Add directory to find the example branding.py (needed by bootloader.py) in ./stubs:
2929
# (Requires pytest >= 7.0.0):
30-
pythonpath=stubs
30+
pythonpath=stubs

pytype_runner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def run_pytype(command: List[str], branch_url: str, errorlog: TextIO, results):
7777
ok = True
7878
while ok:
7979
for key, _ in sel.select():
80-
line = key.fileobj.readline() # type: ignore
80+
line = key.fileobj.readline() # type: ignore[union-attr]
8181
if not line:
8282
ok = False
8383
break

tests/test_bootloader.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,16 @@ def _test_cfg(self, cfg):
1919
universal_newlines=True)
2020

2121
assert proc.stdout is not None # for pyright, to ensure it is valid
22+
# check the diff output, working around trailing whitespace issues
2223
self.assertEqual(proc.stdout.read(), '''5a6,13
2324
> if [ -s $prefix/grubenv ]; then
2425
> load_env
2526
> fi
26-
>
27+
> ''' + '''
2728
> if [ -n "$override_entry" ]; then
2829
> set default=$override_entry
2930
> fi
30-
>
31+
> ''' + '''
3132
''')
3233
proc.stdout.close()
3334
proc.wait()

0 commit comments

Comments
 (0)