help="Whether to strip output from tests that passed")
parser.add_option("--fail-immediately", action="store_true",
help="Whether to stop on the first error", default=False)
-parser.add_option("--prefix", type="string",
+parser.add_option("--prefix", type="string", default='',
help="Add prefix to all test names")
-parser.add_option("--suffix", type="string",
+parser.add_option("--suffix", type="string", default='',
help="Add suffix to all test names")
parser.add_option("--fail-on-empty", default=False,
action="store_true", help="Fail if there was no subunit output")
opts, args = parser.parse_args()
if opts.list:
- prefix = opts.prefix
- suffix = opts.suffix
- if not prefix:
- prefix = ""
- if not suffix:
- suffix = ""
for l in sys.stdin:
- sys.stdout.write("%s%s%s\n" % (prefix, l.rstrip(), suffix))
+ sys.stdout.write("%s%s%s\n" % (opts.prefix, l.rstrip(), opts.suffix))
sys.exit(0)
if opts.expected_failures: