File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -118,7 +118,8 @@ def test_styleguide(self):
118118 stdout = sys .stdout .getvalue ().splitlines ()
119119 self .assertEqual (len (stdout ), report .total_errors )
120120 self .assertEqual (report .total_errors , 1 )
121- self .assertTrue (stdout [0 ].startswith ("missing-file:1:1: E902 IOError" ))
121+ # < 3.3 returns IOError; >= 3.3 returns FileNotFoundError
122+ self .assertTrue (stdout [0 ].startswith ("missing-file:1:1: E902 " ))
122123 self .assertFalse (sys .stderr )
123124 self .reset ()
124125
@@ -289,6 +290,7 @@ def test_styleguide_check_files(self):
289290 self .assertTrue (report .total_errors )
290291
291292 self .assertRaises (TypeError , pep8style .check_files , 42 )
292- self .assertRaises (TypeError , pep8style .check_files , [42 ])
293+ # < 3.3 raises TypeError; >= 3.3 raises AttributeError
294+ self .assertRaises (Exception , pep8style .check_files , [42 ])
293295 # TODO: runner
294296 # TODO: input_file
You can’t perform that action at this time.
0 commit comments