[master 1/2] Fix the dd_test for python3.

dashea installerbot-noreply at redhat.com
Wed Jul 8 19:55:24 UTC 2015


From: David Shea <dshea at redhat.com>

The return of check_output is bytes now.
---
 tests/dd_tests/dd_test.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/dd_tests/dd_test.py b/tests/dd_tests/dd_test.py
index 60ff6b4..7fac060 100644
--- a/tests/dd_tests/dd_test.py
+++ b/tests/dd_tests/dd_test.py
@@ -22,13 +22,13 @@
 def dd_list(dd_path, kernel_ver, anaconda_ver):
     out = subprocess.check_output([os.path.join(UTILDIR, "dd_list"),
             '-d', dd_path, '-k', kernel_ver, '-a', anaconda_ver],
-            stderr=open('/dev/null'))
+            stderr=open('/dev/null')).decode('utf-8')
     return [Driver(*d.split('\n',3)) for d in out.split('\n---\n')[:-1]]
 
 def dd_extract(rpm_path, outdir, kernel_ver, flags='-blmf'):
     out = subprocess.check_output([os.path.join(UTILDIR, "dd_extract"),
             flags, '-r', rpm_path, '-d', outdir, '-k', kernel_ver],
-            stderr=subprocess.STDOUT)
+            stderr=subprocess.STDOUT).decode('utf-8')
     return out
 
 # helpers for creating RPMs to test with


-- 
To view this commit on github, visit https://github.com/rhinstaller/anaconda/commit/eea42da0a3cbd0b6477abaa50b66d989e99faf06


More information about the anaconda-patches mailing list