Skip to content

Commit

Permalink
Use print() function in both Python 2 and Python 3
Browse files Browse the repository at this point in the history
Legacy __print__ statements are syntax errors in Python 3 but __print()__ function works as expected in both Python 2 and Python 3.
  • Loading branch information
cclauss authored and jbergstroem committed Jun 14, 2019
1 parent 09a7faa commit 6b20e15
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tap2junit/tap13.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from __future__ import print_function
# Copyright 2013, Red Hat, Inc.
#
# This program is free software; you can redistribute it and/or modify
Expand Down Expand Up @@ -189,6 +190,6 @@ def parse(self, source):

import pprint
for test in t.tests:
print test.result, test.id, test.description, "#", test.directive, test.comment
print(test.result, test.id, test.description, "#", test.directive, test.comment)
pprint.pprint(test.yaml_buffer)
pprint.pprint(test.yaml)

0 comments on commit 6b20e15

Please sign in to comment.