1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-01 13:09:50 +00:00

meta/selftest/scripts: Use print function for python3 compatibility

Used print function instead of print statement to make
the code work in python 3.

[Changes from both Ed and Richard]

(From OE-Core rev: ced1995694c394d92cb82fb9c25a33dc027a3b69)

Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Richard Purdie
2016-05-21 12:25:02 +01:00
parent 02986886fc
commit ffe9604be2
7 changed files with 32 additions and 33 deletions
+1 -1
View File
@@ -3,4 +3,4 @@ import os
os.system('touch /tmp/testfile.python')
a = 9.01e+21 - 9.01e+21 + 0.01
print "the value of a is %s" % a
print("the value of a is %s" % a)
+3 -3
View File
@@ -153,7 +153,7 @@ class SystemdJournalTests(SystemdTest):
if check_match: break
# put the startup time in the test log
if check_match:
print "%s" % check_match
print("%s" % check_match)
else:
self.skipTest("Error at obtaining the boot time from journalctl")
boot_time_sec = 0
@@ -174,5 +174,5 @@ class SystemdJournalTests(SystemdTest):
self.skipTest("Error when parsing time from boot string")
#Assert the target boot time against systemd's unit start timeout
if boot_time_sec > systemd_TimeoutStartSec:
print "Target boot time %s exceeds systemd's TimeoutStartSec %s"\
%(boot_time_sec, systemd_TimeoutStartSec)
print("Target boot time %s exceeds systemd's TimeoutStartSec %s"\
%(boot_time_sec, systemd_TimeoutStartSec))