diff options
Diffstat (limited to 'machineout.py')
-rw-r--r-- | machineout.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/machineout.py b/machineout.py index 4a29c53..9ba75be 100644 --- a/machineout.py +++ b/machineout.py | |||
@@ -3,7 +3,6 @@ Formats nose output into format easily parsable by machine. | |||
3 | It is intended to be use to integrate nose with your IDE such as Vim. | 3 | It is intended to be use to integrate nose with your IDE such as Vim. |
4 | """ | 4 | """ |
5 | 5 | ||
6 | import re | ||
7 | import os | 6 | import os |
8 | import traceback | 7 | import traceback |
9 | from nose.plugins import Plugin | 8 | from nose.plugins import Plugin |
@@ -71,12 +70,12 @@ class NoseMachineReadableOutput(Plugin): | |||
71 | self.stream.writeln("%s: %s: %s" % (prefix, etype, msg)) | 70 | self.stream.writeln("%s: %s: %s" % (prefix, etype, msg)) |
72 | 71 | ||
73 | if len(lines) > 1: | 72 | if len(lines) > 1: |
74 | pad = ' '*(len(etype)+1) | 73 | pad = ' ' * (len(etype) + 1) |
75 | for line in lines[1:]: | 74 | for line in lines[1:]: |
76 | self.stream.writeln("%s: %s %s" % (prefix, pad, line)) | 75 | self.stream.writeln("%s: %s %s" % (prefix, pad, line)) |
77 | 76 | ||
78 | def _format_testfname(self, fname): | 77 | def _format_testfname(self, fname): |
79 | if fname.startswith(self.basepath): | 78 | if fname.startswith(self.basepath): |
80 | return fname[len(self.basepath)+1:] | 79 | return fname[len(self.basepath) + 1:] |
81 | 80 | ||
82 | return fname | 81 | return fname |