Remove the remaining flavor tuple in test_put_auto_get_capabilities test

There is a remaining flavor tuple after test_put_auto_get_capabilities
test. If zaqar.tests.unit.transport.wsgi.v2_0.test_flavors.
TestFlavorsMongoDB is excuted again after the excution of zaqar.tests.
unit.transport.wsgi.v2_0.test_flavors.TestFlavorsMongoDB,
there are many fails. for example:
zaqar.tests.unit.transport.wsgi.v2_0.test_flavors.TestFlavorsMongoDB.
test_listing_works
File "zaqar/tests/unit/transport/wsgi/v2_0/test_flavors.py", line 314,
in test_listing_works_with_limit,
File "zaqar/tests/unit/transport/wsgi/v2_0/test_flavors.py", line 291,
in _listing_test
testtools.matchers._impl.MismatchError: 0 != 1

Change-Id: I342cd212b6a2ae7d5014e5e49b02a02f21afd9cc
This commit is contained in:
gengchc2 2017-11-05 01:14:58 -07:00
parent b72620dd4d
commit 9d15d948f7
1 changed files with 2 additions and 0 deletions

View File

@ -137,6 +137,8 @@ class TestFlavorsMongoDB(base.V2Base):
doc = {'pool_group': self.pool_group}
self.simulate_put(path, body=jsonutils.dumps(doc))
self.assertEqual(falcon.HTTP_201, self.srmock.status)
# NOTE(gengchc2): Delete it, otherwise exist garbage flavor.
self.simulate_delete(path)
def test_put_existing_overwrites(self):
# NOTE(cabrera): setUp creates default flavor