Remove unneeded glance unit test assert calls

The glance_store library now accepts a verifier object for use with
verifying signatures, as a result of a recently merged patch [1].
There are some glance unit tests that do not expect this verifier
object to be passed to the add method of glance_store, and will
therefore fail with a new release of the glance_store library.

This patch removes the assert lines for the tests that will fail,
since it is not necessary for glance to test glance_store in that
way at the glance level.

[1] https://review.openstack.org/#/c/183110/

Change-Id: I404fbc40dafa159a63a6dfee563f05ee80c073dc
Partial-Bug: #1516031
This commit is contained in:
Brianna Poulos 2016-01-22 15:13:35 -05:00
parent bdee4bbbed
commit eab1567d48
2 changed files with 0 additions and 9 deletions

View File

@ -926,9 +926,6 @@ class TestStoreAddToBackend(utils.BaseTestCase):
self.size,
mstore)
mstore.add.assert_called_once_with(self.image_id, mock.ANY,
self.size, context=None)
def _good_metadata(self, in_metadata):
mstore = mock.Mock()
mstore.add.return_value = (self.location, self.size,
@ -942,9 +939,6 @@ class TestStoreAddToBackend(utils.BaseTestCase):
self.size,
mstore)
mstore.add.assert_called_once_with(self.image_id, mock.ANY,
self.size, context=None)
self.assertEqual(self.location, location)
self.assertEqual(self.size, size)
self.assertEqual(self.checksum, checksum)

View File

@ -110,9 +110,6 @@ class TestUploadUtils(base.StoreClearingUnitTest):
yield (location, checksum, image_meta, image_data, store, notifier,
update_data)
store.add.assert_called_once_with(image_meta['id'], mock.ANY,
image_meta['size'], context=mock.ANY)
def test_upload_data_to_store(self):
# 'user_storage_quota' is not set
def store_add(image_id, data, size, **kwargs):