diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-20 11:17:05 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-06-02 08:24:00 +0100 |
commit | a7309d5790f5dac46e84d3c14959943eb2496fda (patch) | |
tree | 48e1fcb886b8ef2974bade09694356f3230fb8a8 /meta/lib/oeqa/oetest.py | |
parent | 297438e965053b2eb56cc8ef3e59465642f10a24 (diff) | |
download | poky-a7309d5790f5dac46e84d3c14959943eb2496fda.tar.gz |
classes/lib: Update to use python3 command pipeline decoding
In python3, strings are unicode by default. We need to encode/decode
from command pipelines and other places where we interface with the
real world using the correct locales. This patch updates various
call sites to use the correct encoding/decodings.
(From OE-Core rev: bb4685af1bffe17b3aa92a6d21398f38a44ea874)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/oetest.py')
-rw-r--r-- | meta/lib/oeqa/oetest.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oeqa/oetest.py b/meta/lib/oeqa/oetest.py index a50f9d8187..4211ffc379 100644 --- a/meta/lib/oeqa/oetest.py +++ b/meta/lib/oeqa/oetest.py | |||
@@ -132,7 +132,7 @@ class oeSDKTest(oeTest): | |||
132 | return False | 132 | return False |
133 | 133 | ||
134 | def _run(self, cmd): | 134 | def _run(self, cmd): |
135 | return subprocess.check_output(". %s > /dev/null; %s;" % (self.tc.sdkenv, cmd), shell=True) | 135 | return subprocess.check_output(". %s > /dev/null; %s;" % (self.tc.sdkenv, cmd), shell=True).decode("utf-8") |
136 | 136 | ||
137 | class oeSDKExtTest(oeSDKTest): | 137 | class oeSDKExtTest(oeSDKTest): |
138 | def _run(self, cmd): | 138 | def _run(self, cmd): |
@@ -144,7 +144,7 @@ class oeSDKExtTest(oeSDKTest): | |||
144 | env['PATH'] = avoid_paths_in_environ(paths_to_avoid) | 144 | env['PATH'] = avoid_paths_in_environ(paths_to_avoid) |
145 | 145 | ||
146 | return subprocess.check_output(". %s > /dev/null;"\ | 146 | return subprocess.check_output(". %s > /dev/null;"\ |
147 | " %s;" % (self.tc.sdkenv, cmd), shell=True, env=env) | 147 | " %s;" % (self.tc.sdkenv, cmd), shell=True, env=env).decode("utf-8") |
148 | 148 | ||
149 | def getmodule(pos=2): | 149 | def getmodule(pos=2): |
150 | # stack returns a list of tuples containg frame information | 150 | # stack returns a list of tuples containg frame information |