summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/runtime
diff options
context:
space:
mode:
Diffstat (limited to 'meta/lib/oeqa/runtime')
-rw-r--r--meta/lib/oeqa/runtime/files/test.py2
-rw-r--r--meta/lib/oeqa/runtime/parselogs.py4
-rw-r--r--meta/lib/oeqa/runtime/ping.py2
-rw-r--r--meta/lib/oeqa/runtime/systemd.py6
4 files changed, 7 insertions, 7 deletions
diff --git a/meta/lib/oeqa/runtime/files/test.py b/meta/lib/oeqa/runtime/files/test.py
index f3a2273c52..f389225d72 100644
--- a/meta/lib/oeqa/runtime/files/test.py
+++ b/meta/lib/oeqa/runtime/files/test.py
@@ -3,4 +3,4 @@ import os
3os.system('touch /tmp/testfile.python') 3os.system('touch /tmp/testfile.python')
4 4
5a = 9.01e+21 - 9.01e+21 + 0.01 5a = 9.01e+21 - 9.01e+21 + 0.01
6print "the value of a is %s" % a 6print("the value of a is %s" % a)
diff --git a/meta/lib/oeqa/runtime/parselogs.py b/meta/lib/oeqa/runtime/parselogs.py
index a93660131d..242cd8cdd5 100644
--- a/meta/lib/oeqa/runtime/parselogs.py
+++ b/meta/lib/oeqa/runtime/parselogs.py
@@ -238,7 +238,7 @@ class ParseLogsTest(oeRuntimeTest):
238 result = None 238 result = None
239 thegrep = self.build_grepcmd(errors, ignore_errors, log) 239 thegrep = self.build_grepcmd(errors, ignore_errors, log)
240 try: 240 try:
241 result = subprocess.check_output(thegrep, shell=True) 241 result = subprocess.check_output(thegrep, shell=True).decode("utf-8")
242 except: 242 except:
243 pass 243 pass
244 if (result is not None): 244 if (result is not None):
@@ -246,7 +246,7 @@ class ParseLogsTest(oeRuntimeTest):
246 rez = result.splitlines() 246 rez = result.splitlines()
247 for xrez in rez: 247 for xrez in rez:
248 try: 248 try:
249 grep_output = subprocess.check_output(['grep', '-F', xrez, '-B', str(lines_before), '-A', str(lines_after), log]) 249 grep_output = subprocess.check_output(['grep', '-F', xrez, '-B', str(lines_before), '-A', str(lines_after), log]).decode("utf-8")
250 except: 250 except:
251 pass 251 pass
252 results[log.replace('target_logs/','')][xrez]=grep_output 252 results[log.replace('target_logs/','')][xrez]=grep_output
diff --git a/meta/lib/oeqa/runtime/ping.py b/meta/lib/oeqa/runtime/ping.py
index 80c460161b..0f27447926 100644
--- a/meta/lib/oeqa/runtime/ping.py
+++ b/meta/lib/oeqa/runtime/ping.py
@@ -14,7 +14,7 @@ class PingTest(oeRuntimeTest):
14 endtime = time.time() + 60 14 endtime = time.time() + 60
15 while count < 5 and time.time() < endtime: 15 while count < 5 and time.time() < endtime:
16 proc = subprocess.Popen("ping -c 1 %s" % self.target.ip, shell=True, stdout=subprocess.PIPE) 16 proc = subprocess.Popen("ping -c 1 %s" % self.target.ip, shell=True, stdout=subprocess.PIPE)
17 output += proc.communicate()[0] 17 output += proc.communicate()[0].decode("utf-8")
18 if proc.poll() == 0: 18 if proc.poll() == 0:
19 count += 1 19 count += 1
20 else: 20 else:
diff --git a/meta/lib/oeqa/runtime/systemd.py b/meta/lib/oeqa/runtime/systemd.py
index 2b2f10d71c..a96efa28dc 100644
--- a/meta/lib/oeqa/runtime/systemd.py
+++ b/meta/lib/oeqa/runtime/systemd.py
@@ -153,7 +153,7 @@ class SystemdJournalTests(SystemdTest):
153 if check_match: break 153 if check_match: break
154 # put the startup time in the test log 154 # put the startup time in the test log
155 if check_match: 155 if check_match:
156 print "%s" % check_match 156 print("%s" % check_match)
157 else: 157 else:
158 self.skipTest("Error at obtaining the boot time from journalctl") 158 self.skipTest("Error at obtaining the boot time from journalctl")
159 boot_time_sec = 0 159 boot_time_sec = 0
@@ -174,5 +174,5 @@ class SystemdJournalTests(SystemdTest):
174 self.skipTest("Error when parsing time from boot string") 174 self.skipTest("Error when parsing time from boot string")
175 #Assert the target boot time against systemd's unit start timeout 175 #Assert the target boot time against systemd's unit start timeout
176 if boot_time_sec > systemd_TimeoutStartSec: 176 if boot_time_sec > systemd_TimeoutStartSec:
177 print "Target boot time %s exceeds systemd's TimeoutStartSec %s"\ 177 print("Target boot time %s exceeds systemd's TimeoutStartSec %s"\
178 %(boot_time_sec, systemd_TimeoutStartSec) 178 %(boot_time_sec, systemd_TimeoutStartSec))