Skip to content

Instantly share code, notes, and snippets.

@isethi
Created February 18, 2013 02:15
Show Gist options
  • Save isethi/4974754 to your computer and use it in GitHub Desktop.
Save isethi/4974754 to your computer and use it in GitHub Desktop.
# Image list should contain 3 images for TENANT3 with status pending
846 # and owner tenant2
847 path = self._url('/v2/images?member_status=pending&owned_by=tenant2')
848 response = requests.get(path, headers=get_header(TENANT3))
849 self.assertEqual(200, response.status_code)
850 images = json.loads(response.text)['images']
851 self.assertEqual(3, len(images))
852
853 # Image list should contain 1 images for TENANT3 with status pending
854 # and owner tenant2
855 path = self._url('/v2/images?member_status=pending&owner=tenant2')
856 response = requests.get(path, headers=get_header(TENANT3))
857 self.assertEqual(200, response.status_code)
858 images = json.loads(response.text)['images']
859 self.assertEqual(3, len(images))
FAIL: glance.tests.functional.v2.test_images.TestImageMembers.test_image_member_lifecycle
----------------------------------------------------------------------
_StringException: Traceback (most recent call last):
File "/opt/stack/glance/glance/tests/functional/v2/test_images.py", line 859, in test_image_member_lifecycle
self.assertEqual(3, len(images))
MismatchError: 3 != 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment