'Tests that the /images registry API returns list of
public images sorted alphabetically by container_format in
descending order.'

def test_get_index_sort_container_format_desc(self):

    UUID3 = _gen_uuid()
    extra_fixture = self.get_fixture(id=UUID3, name='asdf', disk_format='ami', container_format='ami')
    db_api.image_create(self.context, extra_fixture)
    UUID4 = _gen_uuid()
    extra_fixture = self.get_fixture(id=UUID4, name='xyz', disk_format='iso', container_format='bare')
    db_api.image_create(self.context, extra_fixture)
    images = self.client.get_images(sort_key='container_format', sort_dir='desc')
    self.assertEqualImages(images, (UUID2, UUID4, UUID3), unjsonify=False)
