From: Kyr Shatskyy Date: Wed, 20 Nov 2019 00:01:29 +0000 (+0100) Subject: suite/matrix: make test_build_matrix py3 compat X-Git-Tag: 1.1.0~189^2~8 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=0b822b8455a8b2903759776ff3c4ea05c416b44e;p=teuthology.git suite/matrix: make test_build_matrix py3 compat Signed-off-by: Kyr Shatskyy --- diff --git a/teuthology/suite/test/test_build_matrix.py b/teuthology/suite/test/test_build_matrix.py index aaaa4a11..d0476c34 100644 --- a/teuthology/suite/test/test_build_matrix.py +++ b/teuthology/suite/test/test_build_matrix.py @@ -24,7 +24,7 @@ class TestBuildMatrix(object): 'os.listdir', 'os.path.isfile', 'os.path.isdir', - '__builtin__.open', + 'teuthology.suite.open', ] def setup(self): @@ -582,7 +582,7 @@ class TestSubset(object): 'os.listdir', 'os.path.isfile', 'os.path.isdir', - '__builtin__.open', + 'teuthology.suite.open', ] def setup(self): @@ -637,9 +637,9 @@ class TestSubset(object): sub_max_facets, max_fanout, max_depth - 1, namegen, top=False) if subtree is not None: - tree[namegen.next()] = subtree + tree[next(namegen)] = subtree else: - tree[yamilify(namegen.next())] = None + tree[yamilify(next(namegen))] = None random.choice([ lambda: tree.update({'%': None}), lambda: None])()