Skip to content

Commit fcc93c5

Browse files
committed
Fix tests on Python 2.5
1 parent c85fa44 commit fcc93c5

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

pep8.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1413,6 +1413,8 @@ def check_all(self, expected=None, line_offset=0):
14131413
self.blank_lines = 0
14141414
if COMMENT_WITH_NL:
14151415
# The comment also ends a physical line
1416+
text = text.rstrip('\r\n')
1417+
self.tokens = [(token_type, text) + token[2:]]
14161418
self.check_logical()
14171419
return self.report.get_file_results()
14181420

0 commit comments

Comments
 (0)