From d0f3d937d2a781295b74ba92aa96113b39e0fbdd Mon Sep 17 00:00:00 2001 From: zhurong Date: Mon, 24 Dec 2018 15:49:25 +0800 Subject: [PATCH] Make open file as rb mode for murano rally test Murano rally test will failed when open file as r mode in python3, change open as rb mode to pass the test in python3. Change-Id: I84221bc1991e48cbdd0f07e967719a36b2b8c98e --- rally_openstack/contexts/murano/murano_packages.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rally_openstack/contexts/murano/murano_packages.py b/rally_openstack/contexts/murano/murano_packages.py index 2d8cf27f..a94950e4 100644 --- a/rally_openstack/contexts/murano/murano_packages.py +++ b/rally_openstack/contexts/murano/murano_packages.py @@ -66,7 +66,7 @@ class PackageGenerator(context.Context): # TODO(astudenov): use self.generate_random_name() package = clients.murano().packages.create( {"categories": ["Web"], "tags": ["tag"]}, - {"file": open(zip_name)}) + {"file": open(zip_name, "rb")}) self.context["tenants"][tenant_id]["packages"].append(package)