def test_create_and_get_lqueue(self): queue_id = queuelib.create_lqueue(self.fake_cluster, self.fake_queue) queue_res = queuelib.do_request('GET', queuelib._build_uri_path( 'lqueue', resource_id=queue_id), cluster=self.fake_cluster) self.assertEqual(queue_id, queue_res['uuid']) self.assertEqual('fake_queue', queue_res['display_name'])
def test_delete_lqueue(self): queue_id = queuelib.create_lqueue(self.fake_cluster, self.fake_queue) queuelib.delete_lqueue(self.fake_cluster, queue_id) self.assertRaises(exceptions.NotFound, queuelib.do_request, 'GET', queuelib._build_uri_path('lqueue', resource_id=queue_id), cluster=self.fake_cluster)
def test_create_and_get_lqueue(self): queue_id = queuelib.create_lqueue( self.fake_cluster, self.fake_queue) queue_res = queuelib.do_request( 'GET', queuelib._build_uri_path('lqueue', resource_id=queue_id), cluster=self.fake_cluster) self.assertEqual(queue_id, queue_res['uuid']) self.assertEqual('fake_queue', queue_res['display_name'])
def test_delete_lqueue(self): queue_id = queuelib.create_lqueue( self.fake_cluster, self.fake_queue) queuelib.delete_lqueue(self.fake_cluster, queue_id) self.assertRaises(exceptions.NotFound, queuelib.do_request, 'GET', queuelib._build_uri_path( 'lqueue', resource_id=queue_id), cluster=self.fake_cluster)