diff --git a/cloudkitty/tests/gabbi/handlers.py b/cloudkitty/tests/gabbi/handlers.py index cf4316ca..b0fc160a 100644 --- a/cloudkitty/tests/gabbi/handlers.py +++ b/cloudkitty/tests/gabbi/handlers.py @@ -17,10 +17,10 @@ # import os -from gabbi import handlers +from gabbi.handlers import base -class EnvironStoreHandler(handlers.ResponseHandler): +class EnvironStoreHandler(base.ResponseHandler): """Hackish response handler used to store data in environment. Store data into an environment variable to implement some kind of variable @@ -30,5 +30,6 @@ class EnvironStoreHandler(handlers.ResponseHandler): test_key_value = {} def action(self, test, key, value=None): - data = test.extract_json_path_value(test.json_data, value) + data = test.content_handlers[0].extract_json_path_value( + test.response_data, value) os.environ[key] = test.replace_template(data) diff --git a/test-requirements.txt b/test-requirements.txt index 1de1d4e0..23991205 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -8,7 +8,7 @@ hacking>=0.12.0,!=0.13.0,<0.14 # Apache-2.0 coverage>=3.6 # Apache-2.0 kombu<4.0.0 # BSD ddt>=1.0.1 # MIT -gabbi>=1.11.0,<=1.25.0 # Apache-2.0 +gabbi>=1.26.1 # Apache-2.0 testscenarios>=0.4 # Apache-2.0/BSD testrepository>=0.0.18 # Apache-2.0/BSD mock>=1.2 # BSD diff --git a/tox.ini b/tox.ini index 425fdddd..275d9c6b 100644 --- a/tox.ini +++ b/tox.ini @@ -7,7 +7,7 @@ envlist = py35,py27,pep8 setenv = VIRTUAL_ENV={envdir} PYTHONWARNINGS=default::DeprecationWarning usedevelop = True -install_command = pip install {opts} {packages} +install_command = pip install -c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} {opts} {packages} deps = -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt