From df6ee9b1222ebd81fa22ce3499e536abe7bcb05e Mon Sep 17 00:00:00 2001 From: Cédric Ollivier Date: Mon, 11 Dec 2017 13:44:42 +0100 Subject: Add python3 for Functest utils MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It also fixes test_utils RegexMatch and SubstrMatch. Change-Id: I124aa7d0c4110dcd2f50220aae7ba9b299799e93 Signed-off-by: Cédric Ollivier --- functest/tests/unit/utils/test_openstack_snapshot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'functest/tests/unit/utils/test_openstack_snapshot.py') diff --git a/functest/tests/unit/utils/test_openstack_snapshot.py b/functest/tests/unit/utils/test_openstack_snapshot.py index 33e74609..919b28c6 100644 --- a/functest/tests/unit/utils/test_openstack_snapshot.py +++ b/functest/tests/unit/utils/test_openstack_snapshot.py @@ -222,7 +222,7 @@ class OSSnapshotTesting(unittest.TestCase): return_value=self.update_list), \ mock.patch('functest.utils.openstack_snapshot.get_tenants', return_value=self.update_list), \ - mock.patch('__builtin__.open', mock.mock_open()) as m: + mock.patch('six.moves.builtins.open', mock.mock_open()) as m: openstack_snapshot.main() mock_logger_info.assert_called_once_with("Generating OpenStack " "snapshot...") -- cgit 1.2.3-korg