diff options
author | Claude Paroz <claude@2xlibre.net> | 2011-06-24 12:25:17 -0400 |
---|---|---|
committer | Shaun McCance <shaunm@gnome.org> | 2011-06-24 13:29:55 -0400 |
commit | e84f296dd21de75b9244896be9d2acc6aeed4dea (patch) | |
tree | 0285500589da8372d51c51dc086b1da319419c07 | |
parent | b13436f2a75ffded500e5f26028237d337510394 (diff) | |
download | itstool-e84f296dd21de75b9244896be9d2acc6aeed4dea.tar.gz |
Fixes for Python 3
-rwxr-xr-x | itstool.in | 2 | ||||
-rw-r--r-- | tests/run_tests.py | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -866,7 +866,7 @@ if __name__ == '__main__': (opts, args) = options.parse_args(sys.argv) if opts.version: - print 'itstool ' + VERSION + print('itstool %s' % VERSION) sys.exit(0) if opts.merge is None: diff --git a/tests/run_tests.py b/tests/run_tests.py index 08a9aa1..21c594f 100644 --- a/tests/run_tests.py +++ b/tests/run_tests.py @@ -18,7 +18,7 @@ class ItstoolTests(unittest.TestCase): """ Helper method to run a shell command """ # Set stdout = sys.stdout to debug a subprocess if you set a breakpoint in it pipe = Popen(cmd, shell=True, env=os.environ, stdin=None, stdout=PIPE, stderr=PIPE) - (output, errout) = pipe.communicate() + (output, errout) = map(lambda x:x.decode(), pipe.communicate()) status = pipe.returncode self.assertEqual(status, 0, errout or output) return (status, output, errout) |