diff options
author | Jamie Lennox <jamielennox@redhat.com> | 2015-04-16 15:32:06 +1000 |
---|---|---|
committer | Jamie Lennox <jamielennox@redhat.com> | 2015-04-29 04:12:35 +1000 |
commit | 6431fae5457f314fadcee5e1642f7f87e6a3cbd4 (patch) | |
tree | 0945d6ab7743e4d427a4543b87b568fb06c131d6 | |
parent | d4d7fdc35422b0da1c08e68ab36f31071678105f (diff) | |
download | python-glanceclient-6431fae5457f314fadcee5e1642f7f87e6a3cbd4.tar.gz |
Unorder compare in tests
On occassion the values from schema are presented in a different order.
Compare them in an unordered way as we only care that both are present.
Change-Id: Ib2d44587196f43c73f4b0a3796fac9f4dc20f20f
-rw-r--r-- | glanceclient/tests/unit/v2/test_schemas.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/glanceclient/tests/unit/v2/test_schemas.py b/glanceclient/tests/unit/v2/test_schemas.py index 35788cd..b084d14 100644 --- a/glanceclient/tests/unit/v2/test_schemas.py +++ b/glanceclient/tests/unit/v2/test_schemas.py @@ -121,8 +121,8 @@ class TestController(testtools.TestCase): def test_get_schema(self): schema = self.controller.get('image') self.assertEqual('image', schema.name) - self.assertEqual(['name', 'tags'], - [p.name for p in schema.properties]) + self.assertEqual(set(['name', 'tags']), + set([p.name for p in schema.properties])) class TestSchemaBasedModel(testtools.TestCase): |