From 2afd8b1478331f7ba35f6a38ad3e5fe4329044a8 Mon Sep 17 00:00:00 2001 From: Carlos Goncalves Date: Tue, 9 Aug 2016 20:47:27 +0200 Subject: Change type of nova_api_version from float to str Recently functest container had its python requests lib updated to version 2.8.0 and it no longer supports passing in header values of float type. Change-Id: I31da351d7f5c7c1c3ff5121b7b000f3bab1d76bf Signed-off-by: Carlos Goncalves --- tests/clean.py | 2 +- tests/inspector.py | 2 +- tests/nova_force_down.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/clean.py b/tests/clean.py index af966aed..f8394055 100644 --- a/tests/clean.py +++ b/tests/clean.py @@ -14,7 +14,7 @@ import os import novaclient.client as novaclient -nova_api_version = 2.11 +nova_api_version = '2.11' def enable_compute_host(hostname): self.nova = novaclient.Client(self.nova_api_version, diff --git a/tests/inspector.py b/tests/inspector.py index db7db39e..c8fb00f9 100644 --- a/tests/inspector.py +++ b/tests/inspector.py @@ -20,7 +20,7 @@ import nova_force_down class DoctorInspectorSample(object): - nova_api_version = 2.11 + nova_api_version = '2.11' def __init__(self): self.nova = novaclient.Client(self.nova_api_version, diff --git a/tests/nova_force_down.py b/tests/nova_force_down.py index bb10e9ea..abea5671 100644 --- a/tests/nova_force_down.py +++ b/tests/nova_force_down.py @@ -36,7 +36,7 @@ def force_down(hostname, force_down=True): 'Content-Type': 'application/json', 'Accept': 'application/json', 'X-Auth-Token': keystone.auth_ref['token']['id'], - 'X-OpenStack-Nova-API-Version': 2.11, + 'X-OpenStack-Nova-API-Version': '2.11', } print requests.put(url, data=json.dumps(data), headers=headers) -- cgit 1.2.3-korg