summaryrefslogtreecommitdiffstats
path: root/tests/test_exception.py
diff options
context:
space:
mode:
authorMark McLoughlin <markmc@redhat.com>2013-01-21 15:17:10 +0000
committerMark McLoughlin <markmc@redhat.com>2013-01-22 08:45:52 +0000
commit49447c26a410fface3f77d78f980a8274f2a701e (patch)
tree8bed7b8810aad3e9c00646f0b2c50c1215865315 /tests/test_exception.py
parent8748cfa3a6b7573550e7ec8ced87e6fd2096a628 (diff)
downloadkeystone-49447c26a410fface3f77d78f980a8274f2a701e.tar.gz
keystone-49447c26a410fface3f77d78f980a8274f2a701e.tar.xz
keystone-49447c26a410fface3f77d78f980a8274f2a701e.zip
Sync latest cfg from oslo-incubator
Changes include: c5984ba Move logging config options into the log module 7cf016a Fixing the trim for ListOp when reading from config file The most significant change is that cfg no longer provides logging config options as these have been moved to the log module which keystone does not yet use. Define these options in keystone.config where they are used since pulling in oslo logging isn't appropriate if we're not going to use it. Change-Id: I3913ea54465658d93dc56e014dfe5d911b0541d6
Diffstat (limited to 'tests/test_exception.py')
-rw-r--r--tests/test_exception.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/test_exception.py b/tests/test_exception.py
index a13e3982..13f626a0 100644
--- a/tests/test_exception.py
+++ b/tests/test_exception.py
@@ -79,7 +79,7 @@ class ExceptionTestCase(test.TestCase):
class SecurityErrorTestCase(ExceptionTestCase):
"""Tests whether security-related info is exposed to the API user."""
def test_unauthorized_exposure(self):
- CONF.debug = False
+ self.opt(debug=False)
risky_info = uuid.uuid4().hex
e = exception.Unauthorized(message=risky_info)
@@ -87,7 +87,7 @@ class SecurityErrorTestCase(ExceptionTestCase):
self.assertNotIn(risky_info, str(e))
def test_unauthorized_exposure_in_debug(self):
- CONF.debug = True
+ self.opt(debug=True)
risky_info = uuid.uuid4().hex
e = exception.Unauthorized(message=risky_info)
@@ -95,7 +95,7 @@ class SecurityErrorTestCase(ExceptionTestCase):
self.assertIn(risky_info, str(e))
def test_forbidden_exposure(self):
- CONF.debug = False
+ self.opt(debug=False)
risky_info = uuid.uuid4().hex
e = exception.Forbidden(message=risky_info)
@@ -103,7 +103,7 @@ class SecurityErrorTestCase(ExceptionTestCase):
self.assertNotIn(risky_info, str(e))
def test_forbidden_exposure_in_debug(self):
- CONF.debug = True
+ self.opt(debug=True)
risky_info = uuid.uuid4().hex
e = exception.Forbidden(message=risky_info)
@@ -111,7 +111,7 @@ class SecurityErrorTestCase(ExceptionTestCase):
self.assertIn(risky_info, str(e))
def test_forbidden_action_exposure(self):
- CONF.debug = False
+ self.opt(debug=False)
risky_info = uuid.uuid4().hex
action = uuid.uuid4().hex
@@ -125,7 +125,7 @@ class SecurityErrorTestCase(ExceptionTestCase):
self.assertIn(risky_info, str(e))
def test_forbidden_action_exposure_in_debug(self):
- CONF.debug = True
+ self.opt(debug=True)
risky_info = uuid.uuid4().hex