Initial setup changes of congress-tempest-plugin

Change-Id: I368e7591ad9f10717f17a3bc5afbc49137e373d5
This commit is contained in:
ghanshyam 2017-12-09 14:59:34 +03:00 committed by Anusha Ramineni
parent c80b5ba002
commit bea5c786f3
22 changed files with 98 additions and 31 deletions

59
.gitignore vendored Normal file
View File

@ -0,0 +1,59 @@
*.py[cod]
# C extensions
*.so
# Packages
*.egg*
*.egg-info
dist
build
eggs
parts
bin
var
sdist
develop-eggs
.installed.cfg
lib
lib64
# Installer logs
pip-log.txt
# Unit test / coverage reports
cover/
.coverage*
!.coveragerc
.tox
nosetests.xml
.testrepository
.stestr
.venv
# Translations
*.mo
# Mr Developer
.mr.developer.cfg
.project
.pydevproject
# Complexity
output/*.html
output/*/index.html
# Sphinx
doc/build
# pbr generates these
AUTHORS
ChangeLog
# Editors
*~
.*.swp
.*sw?
# Files created by releasenotes build
releasenotes/build

4
.gitreview Normal file
View File

@ -0,0 +1,4 @@
[gerrit]
host=review.openstack.org
port=29418
project=openstack/congress-tempest-plugin.git

View File

@ -19,14 +19,14 @@ import os
from tempest import config
from tempest.test_discover import plugins
from congress_tempest_tests import config as config_congress
from congress_tempest_plugin import config as config_congress
class CongressTempestPlugin(plugins.TempestPlugin):
def load_tests(self):
base_path = os.path.split(os.path.dirname(
os.path.abspath(__file__)))[0]
test_dir = "congress_tempest_tests/tests"
test_dir = "congress_tempest_plugin/tests"
full_test_dir = os.path.join(base_path, test_dir)
return full_test_dir, base_path

View File

@ -14,7 +14,7 @@ To run only these tests in tempest, go to tempest directory, then run::
To run a single test case, go to tempest directory, then run with test case name, e.g.::
$ ./run_tempest.sh -N -- congress_tempest_tests.tests.scenario.test_congress_basic_ops.TestPolicyBasicOps.test_policy_basic_op
$ ./run_tempest.sh -N -- congress_tempest_plugin.tests.scenario.test_congress_basic_ops.TestPolicyBasicOps.test_policy_basic_op
Alternatively, to run congress tempest plugin tests using tox, go to tempest directory, then run::
@ -22,4 +22,4 @@ Alternatively, to run congress tempest plugin tests using tox, go to tempest dir
And, to run a specific test::
$ tox -eall-plugin congress_tempest_tests.tests.scenario.test_congress_basic_ops.TestPolicyBasicOps.test_policy_basic_op
$ tox -eall-plugin congress_tempest_plugin.tests.scenario.test_congress_basic_ops.TestPolicyBasicOps.test_policy_basic_op

View File

@ -19,7 +19,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -18,7 +18,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -20,7 +20,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -16,8 +16,8 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
class TestDoctorDriver(manager_congress.ScenarioPolicyBase):

View File

@ -20,7 +20,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -18,7 +18,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -18,7 +18,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -19,7 +19,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -20,7 +20,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -21,8 +21,8 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -21,8 +21,8 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -19,8 +19,8 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -18,7 +18,7 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -28,9 +28,9 @@ from tempest.lib import exceptions
from tempest import manager as tempestmanager
from urllib3 import exceptions as urllib3_exceptions
from congress_tempest_tests.services.policy import policy_client
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.services.policy import policy_client
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF
LOG = logging.getLogger(__name__)

View File

@ -45,5 +45,5 @@ def root_path():
x, y = os.path.split(x) # drop "helper.py"
x, y = os.path.split(x) # drop "scenario"
x, y = os.path.split(x) # drop "tests"
x, y = os.path.split(x) # drop "congress_tempest_tests"
x, y = os.path.split(x) # drop "congress_tempest_plugin"
return x

View File

@ -22,11 +22,11 @@ from tempest import config
from tempest.lib.common.utils import data_utils
from tempest import manager as tempestmanager
from congress_tempest_tests.services.congress_network import qos_client
from congress_tempest_tests.services.congress_network import qos_rule_client
from congress_tempest_tests.services.policy import policy_client
from congress_tempest_plugin.services.congress_network import qos_client
from congress_tempest_plugin.services.congress_network import qos_rule_client
from congress_tempest_plugin.services.policy import policy_client
# use local copy of tempest scenario manager during upstream refactoring
from congress_tempest_tests.tests.scenario import manager
from congress_tempest_plugin.tests.scenario import manager
CONF = config.CONF
LOG = logging.getLogger(__name__)

View File

@ -24,8 +24,8 @@ from tempest.lib.common.utils import test_utils
from tempest.lib import decorators
from tempest.lib import exceptions
from congress_tempest_tests.tests.scenario import helper
from congress_tempest_tests.tests.scenario import manager_congress
from congress_tempest_plugin.tests.scenario import helper
from congress_tempest_plugin.tests.scenario import manager_congress
CONF = config.CONF

View File

@ -45,3 +45,7 @@ input_file = congress_tempest_plugin/locale/congress_tempest_plugin.pot
keywords = _ gettext ngettext l_ lazy_gettext
mapping_file = babel.cfg
output_file = congress_tempest_plugin/locale/congress_tempest_plugin.pot
[entry_points]
tempest.test_plugins =
congress_tests = congress_tempest_plugin.plugin:CongressTempestPlugin