Merge "Fix create server request in test_network_v6"
diff --git a/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py b/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
index 2b0f268..b08df97 100644
--- a/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
+++ b/tempest/api/compute/floating_ips/test_floating_ips_actions_negative.py
@@ -89,7 +89,7 @@
@test.services('network')
def test_associate_ip_to_server_without_passing_floating_ip(self):
# Negative test:Association of empty floating IP to specific server
- # should raise NotFound exception
- self.assertRaises(exceptions.NotFound,
+ # should raise NotFound or BadRequest(In case of Nova V2.1) exception.
+ self.assertRaises((exceptions.NotFound, exceptions.BadRequest),
self.client.associate_floating_ip_to_server,
'', self.server_id)
diff --git a/tempest/cli/simple_read_only/compute/test_nova_manage.py b/tempest/cli/simple_read_only/compute/test_nova_manage.py
deleted file mode 100644
index 34ec671..0000000
--- a/tempest/cli/simple_read_only/compute/test_nova_manage.py
+++ /dev/null
@@ -1,96 +0,0 @@
-# Copyright 2013 OpenStack Foundation
-# All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the "License"); you may
-# not use this file except in compliance with the License. You may obtain
-# a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
-# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
-# License for the specific language governing permissions and limitations
-# under the License.
-
-from tempest_lib import exceptions
-
-from tempest import cli
-from tempest import config
-from tempest.openstack.common import log as logging
-
-
-CONF = config.CONF
-LOG = logging.getLogger(__name__)
-
-
-class SimpleReadOnlyNovaManageTest(cli.ClientTestBase):
-
- """
- This is a first pass at a simple read only nova-manage test. This
- only exercises client commands that are read only.
-
- This should test commands:
- * with and without optional parameters
- * initially just check return codes, and later test command outputs
-
- """
-
- @classmethod
- def resource_setup(cls):
- if not CONF.service_available.nova:
- msg = ("%s skipped as Nova is not available" % cls.__name__)
- raise cls.skipException(msg)
- if not CONF.cli.has_manage:
- msg = ("%s skipped as *-manage commands not available"
- % cls.__name__)
- raise cls.skipException(msg)
- super(SimpleReadOnlyNovaManageTest, cls).resource_setup()
-
- def nova_manage(self, *args, **kwargs):
- return self.clients.nova_manage(*args, **kwargs)
-
- def test_admin_fake_action(self):
- self.assertRaises(exceptions.CommandFailed,
- self.nova_manage,
- 'this-does-nova-exist')
-
- # NOTE(jogo): Commands in order listed in 'nova-manage -h'
-
- # test flags
- def test_help_flag(self):
- self.nova_manage('', '-h')
-
- def test_version_flag(self):
- # Bug 1159957: nova-manage --version writes to stderr
- self.assertNotEqual("", self.nova_manage('', '--version',
- merge_stderr=True))
- self.assertEqual(self.nova_manage('version'),
- self.nova_manage('', '--version', merge_stderr=True))
-
- def test_debug_flag(self):
- self.assertNotEqual("", self.nova_manage('service list',
- '--debug'))
-
- def test_verbose_flag(self):
- self.assertNotEqual("", self.nova_manage('service list',
- '--verbose'))
-
- # test actions
- def test_version(self):
- self.assertNotEqual("", self.nova_manage('version'))
-
- def test_db_sync(self):
- # make sure command doesn't error out
- self.nova_manage('db sync')
-
- def test_db_version(self):
- self.assertNotEqual("", self.nova_manage('db version'))
-
- def test_cell_list(self):
- # make sure command doesn't error out
- self.nova_manage('cell list')
-
- def test_host_list(self):
- # make sure command doesn't error out
- self.nova_manage('host list')
diff --git a/tempest/services/network/json/network_client.py b/tempest/services/network/json/network_client.py
index c7ee5f7..e92708c 100644
--- a/tempest/services/network/json/network_client.py
+++ b/tempest/services/network/json/network_client.py
@@ -57,7 +57,7 @@
'ipsecpolicies': 'vpn',
'vpnservices': 'vpn',
'ikepolicies': 'vpn',
- 'ipsecpolicies': 'vpn',
+ 'ipsec-site-connections': 'vpn',
'metering_labels': 'metering',
'metering_label_rules': 'metering',
'firewall_rules': 'fw',
@@ -85,7 +85,7 @@
'security_group_rules': 'security_group_rules',
'ipsecpolicy': 'ipsecpolicies',
'ikepolicy': 'ikepolicies',
- 'ipsecpolicy': 'ipsecpolicies',
+ 'ipsec_site_connection': 'ipsec-site-connections',
'quotas': 'quotas',
'firewall_policy': 'firewall_policies'
}