Refactored Neutron tempest plugin directory structure
* switch from neutron.tests.tempest to neutron_tempest_plugin * Cleaned up README.rst and setup.cfg * Use neutron_tempest_plugin as a tempest plugin package * Fixed gitreview * Keeping flake8 Ignores in tox.ini as tempest plugin is imported from neutron codebase. Change-Id: I42d389836e72813fdeebc797a577f4a8ac2ee603
This commit is contained in:
parent
5e6198734b
commit
667d3d3260
@ -1,4 +1,4 @@
|
|||||||
[gerrit]
|
[gerrit]
|
||||||
host=review.openstack.org
|
host=review.openstack.org
|
||||||
port=29418
|
port=29418
|
||||||
project=openstack/openstack.git
|
project=openstack/neutron-tempest-plugin.git
|
||||||
|
21
README.rst
21
README.rst
@ -1,19 +1,12 @@
|
|||||||
===============================
|
======================
|
||||||
Neutron Tempest Plugin
|
Neutron Tempest Plugin
|
||||||
===============================
|
======================
|
||||||
|
|
||||||
Tempest plugin for Neutron
|
Tempest plugin for Neutron project.
|
||||||
|
|
||||||
Please fill here a long description which must be at least 3 lines wrapped on
|
It contains the tempest plugin for the functional testing of Neutron Project.
|
||||||
80 cols, so that distribution package maintainers can use it in their packages.
|
|
||||||
Note that this is a hard requirement.
|
|
||||||
|
|
||||||
* Free software: Apache license
|
* Free software: Apache license
|
||||||
* Documentation: http://docs.openstack.org/developer/openstack
|
* Documentation: http://docs.openstack.org/developer/neutron
|
||||||
* Source: http://git.openstack.org/cgit/openstack/openstack
|
* Source: http://git.openstack.org/cgit/openstack/neutron-tempest-plugin
|
||||||
* Bugs: http://bugs.launchpad.net/neutron_tempest_plugin
|
* Bugs: http://bugs.launchpad.net/neutron
|
||||||
|
|
||||||
Features
|
|
||||||
--------
|
|
||||||
|
|
||||||
* TODO
|
|
||||||
|
@ -4,6 +4,6 @@ WARNING
|
|||||||
Some files under this path were copied from tempest as part of the move of the
|
Some files under this path were copied from tempest as part of the move of the
|
||||||
api tests, and they will be removed as required over time to minimize the
|
api tests, and they will be removed as required over time to minimize the
|
||||||
dependency on the tempest testing framework. While it exists, only
|
dependency on the tempest testing framework. While it exists, only
|
||||||
neutron.tests.tempest.* should be importing files from this path.
|
neutron_tempest_plugin.* should be importing files from this path.
|
||||||
neutron.tests.tempest.config uses the global cfg.CONF instance and importing it
|
neutron_tempest_plugin.config uses the global cfg.CONF instance and importing it
|
||||||
outside of the api tests has the potential to break Neutron's use of cfg.CONF.
|
outside of the api tests has the potential to break Neutron's use of cfg.CONF.
|
@ -12,10 +12,10 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from neutron.tests.tempest.common import tempest_fixtures
|
from neutron_tempest_plugin.common import tempest_fixtures
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class AgentManagementTestJSON(base.BaseAdminNetworkTest):
|
class AgentManagementTestJSON(base.BaseAdminNetworkTest):
|
@ -15,8 +15,8 @@
|
|||||||
from neutron_lib import constants
|
from neutron_lib import constants
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.common import utils
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.common import utils
|
||||||
|
|
||||||
|
|
||||||
class DHCPAgentSchedulersTestJSON(base.BaseAdminNetworkTest):
|
class DHCPAgentSchedulersTestJSON(base.BaseAdminNetworkTest):
|
@ -16,8 +16,8 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base_security_groups as base_security
|
from neutron_tempest_plugin.api import base_security_groups as base_security
|
||||||
|
|
||||||
|
|
||||||
class PortSecurityAdminTests(base_security.BaseSecGroupTest,
|
class PortSecurityAdminTests(base_security.BaseSecGroupTest,
|
@ -16,7 +16,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class ExternalNetworksRBACTestJSON(base.BaseAdminNetworkTest):
|
class ExternalNetworksRBACTestJSON(base.BaseAdminNetworkTest):
|
@ -18,8 +18,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -15,8 +15,8 @@
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import exceptions
|
from neutron_tempest_plugin import exceptions
|
||||||
|
|
||||||
AGENT_TYPE = 'L3 agent'
|
AGENT_TYPE = 'L3 agent'
|
||||||
AGENT_MODES = (
|
AGENT_MODES = (
|
@ -16,8 +16,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
class NetworksTestAdmin(base.BaseAdminNetworkTest):
|
class NetworksTestAdmin(base.BaseAdminNetworkTest):
|
@ -19,8 +19,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -15,8 +15,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api.admin import test_quotas
|
from neutron_tempest_plugin.api.admin import test_quotas
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -16,7 +16,7 @@
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_routers as base
|
from neutron_tempest_plugin.api import base_routers as base
|
||||||
|
|
||||||
|
|
||||||
class RoutersTestDVR(base.BaseRouterTest):
|
class RoutersTestDVR(base.BaseRouterTest):
|
@ -16,7 +16,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_routers as base
|
from neutron_tempest_plugin.api import base_routers as base
|
||||||
|
|
||||||
|
|
||||||
class RoutersFlavorTestCase(base.BaseRouterTest):
|
class RoutersFlavorTestCase(base.BaseRouterTest):
|
@ -13,7 +13,7 @@
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_routers as base
|
from neutron_tempest_plugin.api import base_routers as base
|
||||||
|
|
||||||
|
|
||||||
class RoutersTestHA(base.BaseRouterTest):
|
class RoutersTestHA(base.BaseRouterTest):
|
@ -21,7 +21,7 @@ from tempest.lib import exceptions as lib_exc
|
|||||||
from tempest import test
|
from tempest import test
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class SharedNetworksTest(base.BaseAdminNetworkTest):
|
class SharedNetworksTest(base.BaseAdminNetworkTest):
|
@ -21,11 +21,11 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.common import constants
|
from neutron_tempest_plugin.api import clients
|
||||||
from neutron.tests.tempest.common import utils
|
from neutron_tempest_plugin.common import constants
|
||||||
from neutron.tests.tempest.api import clients
|
from neutron_tempest_plugin.common import utils
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest import exceptions
|
from neutron_tempest_plugin import exceptions
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -13,7 +13,7 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class BaseRouterTest(base.BaseAdminNetworkTest):
|
class BaseRouterTest(base.BaseAdminNetworkTest):
|
@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class BaseSecGroupTest(base.BaseNetworkTest):
|
class BaseSecGroupTest(base.BaseNetworkTest):
|
@ -19,8 +19,8 @@ from tempest.lib.services.identity.v2 import tenants_client
|
|||||||
from tempest.lib.services.identity.v3 import projects_client
|
from tempest.lib.services.identity.v3 import projects_client
|
||||||
from tempest import manager
|
from tempest import manager
|
||||||
|
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.services.network.json import network_client
|
from neutron_tempest_plugin.services.network.json import network_client
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -17,7 +17,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
ADDRESS_SCOPE_NAME = 'smoke-address-scope'
|
ADDRESS_SCOPE_NAME = 'smoke-address-scope'
|
@ -16,7 +16,7 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import test_address_scopes
|
from neutron_tempest_plugin.api import test_address_scopes
|
||||||
|
|
||||||
|
|
||||||
class AddressScopeTestNegative(test_address_scopes.AddressScopeTestBase):
|
class AddressScopeTestNegative(test_address_scopes.AddressScopeTestBase):
|
@ -16,8 +16,8 @@
|
|||||||
import netaddr
|
import netaddr
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
class AllowedAddressPairTestJSON(base.BaseNetworkTest):
|
class AllowedAddressPairTestJSON(base.BaseNetworkTest):
|
@ -17,7 +17,7 @@ from neutron_lib.api.definitions import auto_allocated_topology
|
|||||||
from oslo_config import cfg
|
from oslo_config import cfg
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class TestAutoAllocatedTopology(base.BaseAdminNetworkTest):
|
class TestAutoAllocatedTopology(base.BaseAdminNetworkTest):
|
@ -18,8 +18,8 @@ from neutron_lib import constants
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -18,8 +18,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base_security_groups as base_security
|
from neutron_tempest_plugin.api import base_security_groups as base_security
|
||||||
|
|
||||||
FAKE_IP = '10.0.0.1'
|
FAKE_IP = '10.0.0.1'
|
||||||
FAKE_MAC = '00:25:64:e8:19:dd'
|
FAKE_MAC = '00:25:64:e8:19:dd'
|
@ -13,7 +13,7 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class ExtensionsTest(base.BaseNetworkTest):
|
class ExtensionsTest(base.BaseNetworkTest):
|
@ -16,7 +16,7 @@
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class ExtraDHCPOptionsTestJSON(base.BaseNetworkTest):
|
class ExtraDHCPOptionsTestJSON(base.BaseNetworkTest):
|
@ -15,7 +15,7 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class TestFlavorsJson(base.BaseAdminNetworkTest):
|
class TestFlavorsJson(base.BaseAdminNetworkTest):
|
@ -17,8 +17,8 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -18,8 +18,8 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -16,7 +16,7 @@ from neutron_lib.db import constants as db_const
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
LONG_NAME_OK = 'x' * db_const.NAME_FIELD_SIZE
|
LONG_NAME_OK = 'x' * db_const.NAME_FIELD_SIZE
|
||||||
|
|
@ -16,7 +16,7 @@ from neutron_lib.db import constants as db_const
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
LONG_NAME_NG = 'x' * (db_const.NAME_FIELD_SIZE + 1)
|
LONG_NAME_NG = 'x' * (db_const.NAME_FIELD_SIZE + 1)
|
||||||
|
|
@ -21,8 +21,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
from neutron_lib import constants as lib_constants
|
from neutron_lib import constants as lib_constants
|
||||||
|
|
@ -16,7 +16,7 @@ from oslo_utils import uuidutils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import test_network_ip_availability as net_ip
|
from neutron_tempest_plugin.api import test_network_ip_availability as net_ip
|
||||||
|
|
||||||
|
|
||||||
class NetworksIpAvailabilityNegativeTest(net_ip.NetworksIpAvailabilityTest):
|
class NetworksIpAvailabilityNegativeTest(net_ip.NetworksIpAvailabilityTest):
|
@ -17,8 +17,8 @@ from tempest.lib import decorators
|
|||||||
from tempest import test
|
from tempest import test
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
class NetworksTestJSON(base.BaseNetworkTest):
|
class NetworksTestJSON(base.BaseNetworkTest):
|
@ -14,7 +14,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class NetworksNegativeTest(base.BaseNetworkTest):
|
class NetworksNegativeTest(base.BaseNetworkTest):
|
@ -16,7 +16,7 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class PortsTestJSON(base.BaseNetworkTest):
|
class PortsTestJSON(base.BaseNetworkTest):
|
@ -20,8 +20,8 @@ from tempest import test
|
|||||||
import testscenarios
|
import testscenarios
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.common import qos_consts
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.common import qos_consts
|
||||||
|
|
||||||
|
|
||||||
load_tests = testscenarios.load_tests_apply_scenarios
|
load_tests = testscenarios.load_tests_apply_scenarios
|
@ -14,7 +14,7 @@ from neutron_lib.db import constants as db_const
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
LONG_NAME_NG = 'z' * (db_const.NAME_FIELD_SIZE + 1)
|
LONG_NAME_NG = 'z' * (db_const.NAME_FIELD_SIZE + 1)
|
||||||
LONG_DESCRIPTION_NG = 'z' * (db_const.LONG_DESCRIPTION_FIELD_SIZE + 1)
|
LONG_DESCRIPTION_NG = 'z' * (db_const.LONG_DESCRIPTION_FIELD_SIZE + 1)
|
@ -16,9 +16,9 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions
|
from tempest.lib import exceptions
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base_security_groups as bsg
|
from neutron_tempest_plugin.api import base_security_groups as bsg
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
class TestRevisions(base.BaseAdminNetworkTest, bsg.BaseSecGroupTest):
|
class TestRevisions(base.BaseAdminNetworkTest, bsg.BaseSecGroupTest):
|
@ -18,10 +18,10 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.common import utils
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base_routers
|
||||||
from neutron.tests.tempest.api import base_routers
|
from neutron_tempest_plugin.common import utils
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -18,7 +18,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_routers as base
|
from neutron_tempest_plugin.api import base_routers as base
|
||||||
|
|
||||||
|
|
||||||
class RoutersNegativeTestBase(base.BaseRouterTest):
|
class RoutersNegativeTestBase(base.BaseRouterTest):
|
@ -16,7 +16,7 @@
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_security_groups as base
|
from neutron_tempest_plugin.api import base_security_groups as base
|
||||||
|
|
||||||
|
|
||||||
class SecGroupTest(base.BaseSecGroupTest):
|
class SecGroupTest(base.BaseSecGroupTest):
|
@ -17,7 +17,7 @@ from neutron_lib.db import constants as db_const
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base_security_groups as base
|
from neutron_tempest_plugin.api import base_security_groups as base
|
||||||
|
|
||||||
LONG_NAME_NG = 'x' * (db_const.NAME_FIELD_SIZE + 1)
|
LONG_NAME_NG = 'x' * (db_const.NAME_FIELD_SIZE + 1)
|
||||||
|
|
@ -12,7 +12,7 @@
|
|||||||
|
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class ServiceTypeManagementTest(base.BaseNetworkTest):
|
class ServiceTypeManagementTest(base.BaseNetworkTest):
|
@ -17,7 +17,7 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
SUBNETPOOL_NAME = 'smoke-subnetpool'
|
SUBNETPOOL_NAME = 'smoke-subnetpool'
|
||||||
SUBNET_NAME = 'smoke-subnet'
|
SUBNET_NAME = 'smoke-subnet'
|
@ -20,7 +20,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import test_subnetpools
|
from neutron_tempest_plugin.api import test_subnetpools
|
||||||
|
|
||||||
|
|
||||||
SUBNETPOOL_NAME = 'smoke-subnetpool'
|
SUBNETPOOL_NAME = 'smoke-subnetpool'
|
@ -12,7 +12,7 @@
|
|||||||
|
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class SubnetsSearchCriteriaTest(base.BaseSearchCriteriaTest):
|
class SubnetsSearchCriteriaTest(base.BaseSearchCriteriaTest):
|
@ -14,7 +14,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
|
|
||||||
|
|
||||||
class TagTestJSON(base.BaseAdminNetworkTest):
|
class TagTestJSON(base.BaseAdminNetworkTest):
|
@ -15,10 +15,10 @@ import copy
|
|||||||
from tempest.lib.common.utils import data_utils
|
from tempest.lib.common.utils import data_utils
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest.api import base_routers
|
from neutron_tempest_plugin.api import base_routers
|
||||||
from neutron.tests.tempest.api import base_security_groups
|
from neutron_tempest_plugin.api import base_security_groups
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -18,8 +18,8 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base
|
from neutron_tempest_plugin.api import base
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
def trunks_cleanup(client, trunks):
|
def trunks_cleanup(client, trunks):
|
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest.api import test_trunk
|
from neutron_tempest_plugin.api import test_trunk
|
||||||
|
|
||||||
|
|
||||||
class TestTrunkDetailsJSON(test_trunk.TrunkTestJSONBase):
|
class TestTrunkDetailsJSON(test_trunk.TrunkTestJSONBase):
|
@ -17,7 +17,7 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.api import test_trunk
|
from neutron_tempest_plugin.api import test_trunk
|
||||||
|
|
||||||
|
|
||||||
class TrunkTestJSON(test_trunk.TrunkTestJSONBase):
|
class TrunkTestJSON(test_trunk.TrunkTestJSONBase):
|
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
from tempest.lib.common import ssh
|
from tempest.lib.common import ssh
|
||||||
|
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
|
|
||||||
|
|
||||||
class Client(ssh.Client):
|
class Client(ssh.Client):
|
@ -18,15 +18,18 @@
|
|||||||
|
|
||||||
"""Utilities and helper functions."""
|
"""Utilities and helper functions."""
|
||||||
|
|
||||||
import threading
|
|
||||||
import eventlet
|
import eventlet
|
||||||
|
import threading
|
||||||
|
import time
|
||||||
|
|
||||||
|
|
||||||
class classproperty(object):
|
class classproperty(object):
|
||||||
def __init__(self, f):
|
def __init__(self, f):
|
||||||
self.func = f
|
self.func = f
|
||||||
|
|
||||||
def __get__(self, obj, owner):
|
def __get__(self, obj, owner):
|
||||||
return self.func(owner)
|
return self.func(owner)
|
||||||
|
|
||||||
|
|
||||||
class WaitTimeout(Exception):
|
class WaitTimeout(Exception):
|
||||||
"""Default exception coming from wait_until_true() function."""
|
"""Default exception coming from wait_until_true() function."""
|
||||||
@ -47,6 +50,7 @@ class LockWithTimer(object):
|
|||||||
def time_to_wait(self):
|
def time_to_wait(self):
|
||||||
return self.timestamp - time.time() + self._threshold
|
return self.timestamp - time.time() + self._threshold
|
||||||
|
|
||||||
|
|
||||||
def wait_until_true(predicate, timeout=60, sleep=1, exception=None):
|
def wait_until_true(predicate, timeout=60, sleep=1, exception=None):
|
||||||
"""
|
"""
|
||||||
Wait until callable predicate is evaluated as True
|
Wait until callable predicate is evaluated as True
|
@ -18,14 +18,12 @@ import os
|
|||||||
|
|
||||||
from tempest.test_discover import plugins
|
from tempest.test_discover import plugins
|
||||||
|
|
||||||
import neutron
|
|
||||||
|
|
||||||
|
|
||||||
class NeutronTempestPlugin(plugins.TempestPlugin):
|
class NeutronTempestPlugin(plugins.TempestPlugin):
|
||||||
def load_tests(self):
|
def load_tests(self):
|
||||||
base_path = os.path.split(os.path.dirname(
|
base_path = os.path.split(os.path.dirname(
|
||||||
os.path.abspath(neutron.__file__)))[0]
|
os.path.abspath(__file__)))[0]
|
||||||
test_dir = "neutron/tests/tempest"
|
test_dir = "neutron_tempest_plugin"
|
||||||
full_test_dir = os.path.join(base_path, test_dir)
|
full_test_dir = os.path.join(base_path, test_dir)
|
||||||
return full_test_dir, base_path
|
return full_test_dir, base_path
|
||||||
|
|
@ -21,10 +21,10 @@ from tempest.lib.common.utils import data_utils
|
|||||||
from tempest.lib.common.utils import test_utils
|
from tempest.lib.common.utils import test_utils
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest.api import base as base_api
|
from neutron_tempest_plugin.api import base as base_api
|
||||||
from neutron.tests.tempest.common import ssh
|
from neutron_tempest_plugin.common import ssh
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import constants
|
from neutron_tempest_plugin.scenario import constants
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -14,8 +14,8 @@
|
|||||||
# under the License.
|
# under the License.
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -15,9 +15,9 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest import config
|
|
||||||
from neutron.tests.tempest.scenario import base
|
|
||||||
from neutron_lib import constants
|
from neutron_lib import constants
|
||||||
|
from neutron_tempest_plugin import config
|
||||||
|
from neutron_tempest_plugin.scenario import base
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -21,10 +21,10 @@ from tempest import test
|
|||||||
import testscenarios
|
import testscenarios
|
||||||
from testscenarios.scenarios import multiply_scenarios
|
from testscenarios.scenarios import multiply_scenarios
|
||||||
|
|
||||||
from neutron.tests.tempest.common import ssh
|
from neutron_tempest_plugin.common import ssh
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
from neutron.tests.tempest.scenario import constants
|
from neutron_tempest_plugin.scenario import constants
|
||||||
|
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
@ -16,8 +16,8 @@
|
|||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
from neutron.tests.tempest.scenario import test_dvr
|
from neutron_tempest_plugin.scenario import test_dvr
|
||||||
|
|
||||||
|
|
||||||
class NetworkMigrationTestBase(base.BaseTempestTestCase,
|
class NetworkMigrationTestBase(base.BaseTempestTestCase,
|
@ -14,8 +14,8 @@
|
|||||||
|
|
||||||
from tempest.lib import decorators
|
from tempest.lib import decorators
|
||||||
|
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
|
|
@ -21,14 +21,14 @@ from tempest.lib import decorators
|
|||||||
from tempest.lib import exceptions
|
from tempest.lib import exceptions
|
||||||
from tempest import test
|
from tempest import test
|
||||||
|
|
||||||
from neutron.tests.tempest.common import utils
|
from neutron_tempest_plugin.api import base as base_api
|
||||||
from neutron.tests.tempest.common import qos_consts
|
from neutron_tempest_plugin.common import qos_consts
|
||||||
from neutron.tests.tempest.api import base as base_api
|
from neutron_tempest_plugin.common import ssh
|
||||||
from neutron.tests.tempest.common import ssh
|
from neutron_tempest_plugin.common import utils
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
from neutron.tests.tempest.scenario import constants
|
from neutron_tempest_plugin.scenario import constants
|
||||||
from neutron.tests.tempest.scenario import exceptions as sc_exceptions
|
from neutron_tempest_plugin.scenario import exceptions as sc_exceptions
|
||||||
|
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
@ -154,9 +154,9 @@ class QoSTest(base.BaseTempestTestCase):
|
|||||||
CONF.validation.image_ssh_user,
|
CONF.validation.image_ssh_user,
|
||||||
pkey=self.keypair['private_key'])
|
pkey=self.keypair['private_key'])
|
||||||
policy = self.os_admin.network_client.create_qos_policy(
|
policy = self.os_admin.network_client.create_qos_policy(
|
||||||
name='test-policy',
|
name='test-policy',
|
||||||
description='test-qos-policy',
|
description='test-qos-policy',
|
||||||
shared=True)
|
shared=True)
|
||||||
policy_id = policy['policy']['id']
|
policy_id = policy['policy']['id']
|
||||||
self.os_admin.network_client.create_bandwidth_limit_rule(
|
self.os_admin.network_client.create_bandwidth_limit_rule(
|
||||||
policy_id, max_kbps=constants.LIMIT_KILO_BITS_PER_SECOND,
|
policy_id, max_kbps=constants.LIMIT_KILO_BITS_PER_SECOND,
|
@ -20,11 +20,11 @@ from tempest.lib import decorators
|
|||||||
from tempest import test
|
from tempest import test
|
||||||
import testtools
|
import testtools
|
||||||
|
|
||||||
from neutron.tests.tempest.common import utils
|
from neutron_tempest_plugin.common import ssh
|
||||||
from neutron.tests.tempest.common import ssh
|
from neutron_tempest_plugin.common import utils
|
||||||
from neutron.tests.tempest import config
|
from neutron_tempest_plugin import config
|
||||||
from neutron.tests.tempest.scenario import base
|
from neutron_tempest_plugin.scenario import base
|
||||||
from neutron.tests.tempest.scenario import constants
|
from neutron_tempest_plugin.scenario import constants
|
||||||
|
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
CONF = config.CONF
|
CONF = config.CONF
|
@ -17,7 +17,7 @@ from six.moves.urllib import parse as urlparse
|
|||||||
from tempest.lib.common import rest_client as service_client
|
from tempest.lib.common import rest_client as service_client
|
||||||
from tempest.lib import exceptions as lib_exc
|
from tempest.lib import exceptions as lib_exc
|
||||||
|
|
||||||
from neutron.tests.tempest import exceptions
|
from neutron_tempest_plugin import exceptions
|
||||||
|
|
||||||
|
|
||||||
class NetworkClientJSON(service_client.RestClient):
|
class NetworkClientJSON(service_client.RestClient):
|
16
setup.cfg
16
setup.cfg
@ -1,6 +1,6 @@
|
|||||||
[metadata]
|
[metadata]
|
||||||
name = openstack
|
name = neutron_tempest_plugin
|
||||||
summary = Tempest plugin neutron_tempest_plugin
|
summary = Tempest plugin for Neutron Project
|
||||||
description-file =
|
description-file =
|
||||||
README.rst
|
README.rst
|
||||||
author = OpenStack
|
author = OpenStack
|
||||||
@ -21,7 +21,7 @@ classifier =
|
|||||||
|
|
||||||
[files]
|
[files]
|
||||||
packages =
|
packages =
|
||||||
neutron
|
neutron_tempest_plugin
|
||||||
|
|
||||||
[build_sphinx]
|
[build_sphinx]
|
||||||
all-files = 1
|
all-files = 1
|
||||||
@ -37,15 +37,15 @@ directory = neutron/locale
|
|||||||
domain = neutron
|
domain = neutron
|
||||||
|
|
||||||
[update_catalog]
|
[update_catalog]
|
||||||
domain = neutron
|
domain = neutron_tempest_plugin
|
||||||
output_dir = neutron/locale
|
output_dir = neutron_tempest_plugin/locale
|
||||||
input_file = neutron/locale/neutron_tempest_plugin.pot
|
input_file = neutron_tempest_plugin/locale/neutron_tempest_plugin.pot
|
||||||
|
|
||||||
[extract_messages]
|
[extract_messages]
|
||||||
keywords = _ gettext ngettext l_ lazy_gettext
|
keywords = _ gettext ngettext l_ lazy_gettext
|
||||||
mapping_file = babel.cfg
|
mapping_file = babel.cfg
|
||||||
output_file = neutron/locale/neutron_tempest_plugin.pot
|
output_file = neutron_tempest_plugin/locale/neutron_tempest_plugin.pot
|
||||||
|
|
||||||
[entry_points]
|
[entry_points]
|
||||||
tempest.test_plugins =
|
tempest.test_plugins =
|
||||||
neutron_tests = neutron.tests.tempest.plugin:NeutronTempestPlugin
|
neutron_tests = neutron_tempest_plugin.plugin:NeutronTempestPlugin
|
||||||
|
25
tox.ini
25
tox.ini
@ -32,9 +32,22 @@ commands =
|
|||||||
commands = oslo_debug_helper {posargs}
|
commands = oslo_debug_helper {posargs}
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
# E123, E125 skipped as they are invalid PEP-8.
|
# E125 continuation line does not distinguish itself from next logical line
|
||||||
|
# E126 continuation line over-indented for hanging indent
|
||||||
show-source = True
|
# E128 continuation line under-indented for visual indent
|
||||||
ignore = E123,E125
|
# E129 visually indented line with same indent as next logical line
|
||||||
builtins = _
|
# E265 block comment should start with '# '
|
||||||
exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build
|
# H404 multi line docstring should start with a summary
|
||||||
|
# H405 multi line docstring summary not separated with an empty line
|
||||||
|
# N530 direct neutron imports not allowed
|
||||||
|
# TODO(ihrachys) figure out what to do with N534 and N536
|
||||||
|
# N534 Untranslated exception message
|
||||||
|
# N536 Use assertIsNone rather than assertEqual to check for None values
|
||||||
|
ignore = E125,E126,E128,E129,E265,H404,H405,N530,N534,N536
|
||||||
|
# H106: Don't put vim configuration in source files
|
||||||
|
# H203: Use assertIs(Not)None to check for None
|
||||||
|
# H904: Delay string interpolations at logging calls
|
||||||
|
enable-extensions=H106,H203,H904
|
||||||
|
show-source = true
|
||||||
|
exclude = ./.*,build,dist,doc
|
||||||
|
import-order-style = pep8
|
||||||
|
Loading…
Reference in New Issue
Block a user