aboutsummaryrefslogtreecommitdiffstats
path: root/test.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@tremily.us>2012-11-12 12:18:23 -0500
committerW. Trevor King <wking@tremily.us>2012-11-12 12:18:23 -0500
commit888300a933b32c1edf9cdecd0d24d6b30c6c4ed5 (patch)
treeefbc32aab18ad6f55953e8438e67e5b1113a633b /test.py
parent8726ab9b7169bea404032a3035563f1144582041 (diff)
downloadbugseverywhere-888300a933b32c1edf9cdecd0d24d6b30c6c4ed5.tar.gz
test: convert to Python 3 compatibility
Diffstat (limited to 'test.py')
-rw-r--r--test.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/test.py b/test.py
index e82b419..0604528 100644
--- a/test.py
+++ b/test.py
@@ -62,8 +62,8 @@ def python_tree(root_path='libbe', root_modname='libbe'):
def add_module_tests(suite, modname):
try:
mod = import_by_name(modname)
- except ValueError, e:
- print >> sys.stderr, 'Failed to import "%s"' % (modname)
+ except ValueError as e:
+ sys.stderr.write('Failed to import "{}"\n'.format(modname))
raise e
if hasattr(mod, 'suite'):
s = mod.suite
@@ -92,7 +92,7 @@ those modules and their submodules. For example::
parser.add_option('-q', '--quiet', action='store_true', default=False,
help='Run unittests in quiet mode (verbosity 1).')
options,args = parser.parse_args()
- print >> sys.stderr, 'Testing BE\n%s' % version(verbose=True)
+ sys.stderr.write('Testing BE\n{}\n'.format(version(verbose=True)))
verbosity = 2
if options.quiet == True: