Fix db calls for snaphsot and volume mapping
* Fix misuse of project_only * Includes failing tests * Adds missing call to db/api.py * Fixes bug 1017816 Change-Id: I993089ba031a05e7ab0ea91c279a2ac47593eda3
This commit is contained in:
		| @@ -401,6 +401,16 @@ class DbApiTestCase(test.TestCase): | ||||
|         result = db.fixed_ip_disassociate_all_by_timeout(ctxt, 'bar', now) | ||||
|         self.assertEqual(result, 0) | ||||
|  | ||||
|     def test_get_vol_mapping_non_admin(self): | ||||
|         ref = db.ec2_volume_create(self.context, 'fake-uuid') | ||||
|         ec2_id = db.get_ec2_volume_id_by_uuid(self.context, 'fake-uuid') | ||||
|         self.assertEqual(ref['id'], ec2_id) | ||||
|  | ||||
|     def test_get_snap_mapping_non_admin(self): | ||||
|         ref = db.ec2_snapshot_create(self.context, 'fake-uuid') | ||||
|         ec2_id = db.get_ec2_snapshot_id_by_uuid(self.context, 'fake-uuid') | ||||
|         self.assertEqual(ref['id'], ec2_id) | ||||
|  | ||||
|  | ||||
| def _get_fake_aggr_values(): | ||||
|     return {'name': 'fake_aggregate', | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Vishvananda Ishaya
					Vishvananda Ishaya