summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Martinelli <stevemar@ca.ibm.com>2016-03-08 07:29:03 -0500
committerSteve Martinelli <stevemar@ca.ibm.com>2016-03-08 12:41:17 +0000
commit3ed5d232bbd6dcf4e9e23e8c7f3567ce2999315a (patch)
treee7adcebda8ca07efceed9c9708c64fbd6d8dea19
parent762c4c9bdf66995198fa03751b861a859b9d44a1 (diff)
downloadpython-openstackclient-3ed5d232bbd6dcf4e9e23e8c7f3567ce2999315a.tar.gz
remove py26 workaround in osc
we don't support py2.6, so let's remove the workarounds we have. Change-Id: Id9c8fda065d4aceba3192b044b5c5f2124ee204f
-rw-r--r--openstackclient/tests/utils.py24
1 files changed, 0 insertions, 24 deletions
diff --git a/openstackclient/tests/utils.py b/openstackclient/tests/utils.py
index d3f3853f..319c1c11 100644
--- a/openstackclient/tests/utils.py
+++ b/openstackclient/tests/utils.py
@@ -17,7 +17,6 @@
import os
import fixtures
-import sys
import testtools
from openstackclient.tests import fakes
@@ -50,29 +49,6 @@ class TestCase(testtools.TestCase):
msg = 'method %s should not have been called' % m
self.fail(msg)
- # 2.6 doesn't have the assert dict equals so make sure that it exists
- if tuple(sys.version_info)[0:2] < (2, 7):
-
- def assertIsInstance(self, obj, cls, msg=None):
- """self.assertTrue(isinstance(obj, cls)), with a nicer message"""
-
- if not isinstance(obj, cls):
- standardMsg = '%s is not an instance of %r' % (obj, cls)
- self.fail(self._formatMessage(msg, standardMsg))
-
- def assertDictEqual(self, d1, d2, msg=None):
- # Simple version taken from 2.7
- self.assertIsInstance(d1, dict,
- 'First argument is not a dictionary')
- self.assertIsInstance(d2, dict,
- 'Second argument is not a dictionary')
- if d1 != d2:
- if msg:
- self.fail(msg)
- else:
- standardMsg = '%r != %r' % (d1, d2)
- self.fail(standardMsg)
-
class TestCommand(TestCase):
"""Test cliff command classes"""