From 15c0c710365e9988d9dfc09d3f7e93c75a75852e Mon Sep 17 00:00:00 2001 From: Chris Dent Date: Wed, 28 Sep 2016 17:24:43 +0100 Subject: [PATCH] Add STRICT_RESPONSE_HEADERS check to gabbi tests This uses a new feature in wsgi_intercept 1.4.1 that checks to make sure that response headers are native str type (different things in Python 2 and 3). Since Pecan is well behaved this "just works". Tested locally with both py27 and py35. Change-Id: I1406cfbfa14f69132fc91549779424b8427e7b78 --- gnocchi/tests/gabbi/test_gabbi.py | 2 ++ setup.cfg | 1 + 2 files changed, 3 insertions(+) diff --git a/gnocchi/tests/gabbi/test_gabbi.py b/gnocchi/tests/gabbi/test_gabbi.py index 48c1edb9..ea2222d0 100644 --- a/gnocchi/tests/gabbi/test_gabbi.py +++ b/gnocchi/tests/gabbi/test_gabbi.py @@ -18,10 +18,12 @@ import os from gabbi import driver +import wsgi_intercept from gnocchi.tests.gabbi import fixtures +wsgi_intercept.STRICT_RESPONSE_HEADERS = True TESTS_DIR = 'gabbits' diff --git a/setup.cfg b/setup.cfg index 5a5119ab..93d67546 100644 --- a/setup.cfg +++ b/setup.cfg @@ -75,6 +75,7 @@ test = doc8 tooz>=1.38 keystonemiddleware>=4.0.0 + wsgi_intercept>=1.4.1 [global] setup-hooks =