Skip to content

Commit db02592

Browse files
committed
Ensure \n at the end of tests updates
1 parent e2d377e commit db02592

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

tests/functional/test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ def updateTest(tfname: str, pattern_, strip_blanks: bool = True):
240240
lines = get_file_lines(tfname, replace_regexp=pattern_, replace_what=ZXBASIC_ROOT,
241241
replace_with=_original_root, strip_blanks=strip_blanks)
242242
with src.api.utils.open_file(tfname, 'wt', encoding='utf-8') as f:
243-
f.write('\n'.join(lines))
243+
f.write('\n'.join(lines) + '\n')
244244

245245

246246
@src.api.utils.timeout(_timeout)
@@ -506,7 +506,7 @@ def normalizeDiff(diff: List[str]) -> List[str]:
506506
lines = get_file_lines(tfname, replace_regexp=FILTER, replace_what=ZXBASIC_ROOT,
507507
replace_with=_original_root)
508508
with src.api.utils.open_file(fname1, 'wt', encoding='utf-8') as f:
509-
f.write('\n'.join(lines))
509+
f.write('\n'.join(lines) + '\n')
510510

511511
os.unlink(tfname)
512512
_msg("\rTest: %s (%s) updated\n" % (fname, fname1))

0 commit comments

Comments
 (0)