From 31f326dab688cab0274b3326ca3a5d3c6cf547fc Mon Sep 17 00:00:00 2001 From: Brant Knudson Date: Mon, 8 Jun 2015 20:36:02 -0500 Subject: Unit tests catch deprecated function usage Rather than continue to call deprecated functions without knowing it, have the unit tests fail when deprecated function is used. This will ensure that code isn't added that calls deprecated functions. Change-Id: If9f58e30a08a88778e4ae3fc01399ad90997e812 --- keystoneclient/tests/unit/test_hacking_checks.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'keystoneclient/tests/unit/test_hacking_checks.py') diff --git a/keystoneclient/tests/unit/test_hacking_checks.py b/keystoneclient/tests/unit/test_hacking_checks.py index 220d258..2e4cc1d 100644 --- a/keystoneclient/tests/unit/test_hacking_checks.py +++ b/keystoneclient/tests/unit/test_hacking_checks.py @@ -21,6 +21,9 @@ from keystoneclient.tests.unit import client_fixtures class TestCheckOsloNamespaceImports(testtools.TestCase): + def setUp(self): + super(TestCheckOsloNamespaceImports, self).setUp() + self.useFixture(client_fixtures.Deprecations()) # We are patching pep8 so that only the check under test is actually # installed. -- cgit v1.2.1