Exemplo n.º 1
0
 def test_update_quota_noargs(self):
     resource = 'quota'
     cmd = test_quota.UpdateQuota(test_cli20.MyApp(sys.stdout), None)
     args = [self.test_id]
     self.assertRaises(exceptions.CommandError, self._test_update_resource,
                       resource, cmd, self.test_id, args=args,
                       extrafields=None)
Exemplo n.º 2
0
 def test_update_quota_positional(self):
     resource = 'quota'
     cmd = test_quota.UpdateQuota(
         test_cli20.MyApp(sys.stdout), None)
     args = [self.test_id, '--network', 'test']
     self.assertRaises(
         exceptions.NeutronClientException, self._test_update_resource,
         resource, cmd, self.test_id, args=args,
         extrafields={'network': 'new'})
Exemplo n.º 3
0
 def test_update_quota(self):
     resource = 'quota'
     cmd = test_quota.UpdateQuota(
         test_cli20.MyApp(sys.stdout), None)
     args = ['--tenant-id', self.test_id, '--network', 'test']
     self.assertRaises(
         exceptions.CommandError, self._test_update_resource,
         resource, cmd, self.test_id, args=args,
         extrafields={'network': 'new'})