cd5a32c5f9
virtcli-python2-to-python3-conversion.patch virtconv-python2-to-python3-conversion.patch virtinst-python2-to-python3-conversion.patch virtman-python2-to-python3-conversion.patch virtmisc-python2-to-python3-conversion.patch virttests-python2-to-python3-conversion.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=381
112 lines
3.7 KiB
Diff
112 lines
3.7 KiB
Diff
Index: virt-manager-1.4.3/tests/clitest.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/clitest.py
|
|
+++ virt-manager-1.4.3/tests/clitest.py
|
|
@@ -218,7 +218,7 @@ class Command(object):
|
|
|
|
try:
|
|
conn = None
|
|
- for idx in reversed(range(len(self.argv))):
|
|
+ for idx in reversed(list(range(len(self.argv)))):
|
|
if self.argv[idx] == "--connect":
|
|
conn = utils.openconn(self.argv[idx + 1])
|
|
break
|
|
Index: virt-manager-1.4.3/tests/uitests/utils.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/uitests/utils.py
|
|
+++ virt-manager-1.4.3/tests/uitests/utils.py
|
|
@@ -1,4 +1,4 @@
|
|
-from __future__ import print_function
|
|
+
|
|
|
|
import os
|
|
import re
|
|
Index: virt-manager-1.4.3/tests/utils.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/utils.py
|
|
+++ virt-manager-1.4.3/tests/utils.py
|
|
@@ -96,11 +96,11 @@ def openconn(uri):
|
|
conn.fetch_all_nodedevs()
|
|
|
|
_conn_cache[uri] = {}
|
|
- for key, value in conn._fetch_cache.items():
|
|
+ for key, value in list(conn._fetch_cache.items()):
|
|
_conn_cache[uri][key] = value[:]
|
|
|
|
# Prime the internal connection cache
|
|
- for key, value in _conn_cache[uri].items():
|
|
+ for key, value in list(_conn_cache[uri].items()):
|
|
conn._fetch_cache[key] = value[:]
|
|
|
|
def cb_cache_new_pool(poolobj):
|
|
Index: virt-manager-1.4.3/tests/test_inject.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/test_inject.py
|
|
+++ virt-manager-1.4.3/tests/test_inject.py
|
|
@@ -1,7 +1,7 @@
|
|
#!/usr/bin/env python2
|
|
# Copyright (C) 2013, 2014 Red Hat, Inc.
|
|
|
|
-from __future__ import print_function
|
|
+
|
|
|
|
import atexit
|
|
import os
|
|
@@ -29,7 +29,7 @@ FEDORA_URL = "http://dl.fedoraproject.or
|
|
|
|
(WARN_RHEL4,
|
|
WARN_RHEL5,
|
|
- WARN_LATEST) = range(1, 4)
|
|
+ WARN_LATEST) = list(range(1, 4))
|
|
|
|
|
|
def prompt():
|
|
@@ -185,7 +185,7 @@ def _make_tests():
|
|
return lambda s: _test_distro(_d)
|
|
|
|
idx = 0
|
|
- for dname, dobj in _alldistros.items():
|
|
+ for dname, dobj in list(_alldistros.items()):
|
|
idx += 1
|
|
setattr(FetchTests, "testFetch%.3d_%s" %
|
|
(idx, dname.replace("-", "_")), _make_fetch_cb(dobj))
|
|
Index: virt-manager-1.4.3/tests/test_urls.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/test_urls.py
|
|
+++ virt-manager-1.4.3/tests/test_urls.py
|
|
@@ -346,7 +346,7 @@ def _make_tests():
|
|
d.distroclass = None
|
|
urls[d.name] = d
|
|
|
|
- keys = urls.keys()
|
|
+ keys = list(urls.keys())
|
|
keys.sort()
|
|
for key in keys:
|
|
distroobj = urls[key]
|
|
Index: virt-manager-1.4.3/tests/virtconvtest.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/virtconvtest.py
|
|
+++ virt-manager-1.4.3/tests/virtconvtest.py
|
|
@@ -15,7 +15,7 @@
|
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
|
# MA 02110-1301 USA.
|
|
|
|
-from __future__ import print_function
|
|
+
|
|
|
|
import glob
|
|
import io
|
|
Index: virt-manager-1.4.3/tests/nodedev.py
|
|
===================================================================
|
|
--- virt-manager-1.4.3.orig/tests/nodedev.py
|
|
+++ virt-manager-1.4.3/tests/nodedev.py
|
|
@@ -69,7 +69,7 @@ class TestNodeDev(unittest.TestCase):
|
|
|
|
def _testCompare(self, devname, vals, devxml=None):
|
|
def _compare(dev, vals, root=""):
|
|
- for attr in vals.keys():
|
|
+ for attr in list(vals.keys()):
|
|
expect = vals[attr]
|
|
actual = getattr(dev, attr)
|
|
if isinstance(expect, list):
|