Run 3rd-party test suites without excess dependences
- each test method is parametrized with ENV_NAME to
get unique names in JUnit reports for different
configurations
Change-Id: I8db671d1687f287dc8ca97782cd7bbdf0eaef988
diff --git a/jobs/pipelines/deploy-cicd-and-run-tests.groovy b/jobs/pipelines/deploy-cicd-and-run-tests.groovy
index 27dbfd7..3e96c84 100644
--- a/jobs/pipelines/deploy-cicd-and-run-tests.groovy
+++ b/jobs/pipelines/deploy-cicd-and-run-tests.groovy
@@ -24,7 +24,7 @@
shared.swarm_deploy_cicd(env.DRIVETRAIN_STACK_INSTALL)
}
- stage("Install core infrastructure and deploy CICD nodes") {
+ stage("Deploy platform components") {
// steps: env.PLATFORM_STACK_INSTALL
shared.swarm_deploy_platform(env.PLATFORM_STACK_INSTALL)
}
@@ -40,8 +40,6 @@
if ("${env.SHUTDOWN_ENV_ON_TEARDOWN}" == "false") {
shared.run_cmd("""\
dos.py resume ${ENV_NAME} || true
- sleep 20 # Wait for I/O on the host calms down
- dos.py time-sync ${ENV_NAME} || true
""")
} else {
shared.run_cmd("""\
@@ -72,8 +70,6 @@
if ("${env.SHUTDOWN_ENV_ON_TEARDOWN}" == "false") {
shared.run_cmd("""\
dos.py resume ${ENV_NAME} || true
- sleep 20 # Wait for I/O on the host calms down
- dos.py time-sync ${ENV_NAME} || true
""")
} else {
shared.run_cmd("""\
diff --git a/jobs/pipelines/swarm-run-pytest.groovy b/jobs/pipelines/swarm-run-pytest.groovy
index 52dd25d..553b8a2 100644
--- a/jobs/pipelines/swarm-run-pytest.groovy
+++ b/jobs/pipelines/swarm-run-pytest.groovy
@@ -53,6 +53,7 @@
export ${it}_installed=true"""}.join("\n")
shared.run_cmd(sources + installed + """
+ export TESTS_CONFIGS=${ENV_NAME}_salt_deployed.ini
export MANAGER=devops # use 'hardware' fixture to manage fuel-devops environment
export salt_master_host=\$SALT_MASTER_IP # skip salt_deployed fixture
export salt_master_port=6969
diff --git a/jobs/pipelines/swarm-testrail-report.groovy b/jobs/pipelines/swarm-testrail-report.groovy
index 7d2ce53..333547a 100644
--- a/jobs/pipelines/swarm-testrail-report.groovy
+++ b/jobs/pipelines/swarm-testrail-report.groovy
@@ -37,55 +37,76 @@
def testrail_name_template = ''
def reporter_extra_options = []
- //stage("Archive all xml reports") {
- // archiveArtifacts artifacts: "${PARENT_WORKSPACE}/*.xml"
- //}
-
- stage("Deployment report") {
- report_name = "deployment_${ENV_NAME}.xml"
- testSuiteName = "[MCP] Integration automation"
- methodname = '{methodname}'
- testrail_name_template = '{title}'
- reporter_extra_options = [
- "--testrail-add-missing-cases",
- "--testrail-case-custom-fields {\\\"custom_qa_team\\\":\\\"9\\\"}",
- "--testrail-case-section-name \'All\'",
- ]
- shared.upload_results_to_testrail(report_name, testSuiteName, methodname, testrail_name_template, reporter_extra_options)
+ stage("Archive all xml reports") {
+ archiveArtifacts artifacts: "**/*.xml"
}
- stage("tcp-qa cases report") {
- report_name = "nosetests.xml"
- testSuiteName = "[MCP_X] integration cases"
- methodname = "{methodname}"
- testrail_name_template = "{title}"
- shared.upload_results_to_testrail(report_name, testSuiteName, methodname, testrail_name_template)
- }
+ def deployment_report_name = sh(script: "find ${PARENT_WORKSPACE} -name \"deployment_${ENV_NAME}.xml\"", returnStdout: true)
+ def tcpqa_report_name = sh(script: "find ${PARENT_WORKSPACE} -name \"nosetests.xml\"", returnStdout: true)
+ def tempest_report_name = sh(script: "find ${PARENT_WORKSPACE} -name \"report_*.xml\"", returnStdout: true)
+ def k8s_conformance_report_name = sh(script: "find ${PARENT_WORKSPACE} -name \"conformance_result.xml\"", returnStdout: true)
+ def stacklight_report_name = sh(script: "find ${PARENT_WORKSPACE} -name \"stacklight_report.xml\"", returnStdout: true)
+ common.printMsg(deployment_report_name ? "Found deployment report: ${deployment_report_name}" : "Deployment report not found", deployment_report_name ? "blue" : "red")
+ common.printMsg(tcpqa_report_name ? "Found tcp-qa report: ${tcpqa_report_name}" : "tcp-qa report not found", tcpqa_report_name ? "blue" : "red")
+ common.printMsg(tempest_report_name ? "Found tempest report: ${tempest_report_name}" : "tempest report not found", tempest_report_name ? "blue" : "red")
+ common.printMsg(k8s_conformance_report_name ? "Found k8s conformance report: ${k8s_conformance_report_name}" : "k8s conformance report not found", k8s_conformance_report_name ? "blue" : "red")
+ common.printMsg(stacklight_report_name ? "Found stacklight-pytest report: ${stacklight_report_name}" : "stacklight-pytest report not found", stacklight_report_name ? "blue" : "red")
- if ('openstack' in stacks) {
- stage("Tempest report") {
- report_name = "report_*.xml"
- testSuiteName = "[MCP1.1_PIKE]Tempest"
- methodname = "{classname}.{methodname}"
- testrail_name_template = "{title}"
- shared.upload_results_to_testrail(report_name, testSuiteName, methodname, testrail_name_template)
+
+ if (deployment_report_name) {
+ stage("Deployment report") {
+// report_name = "deployment_${ENV_NAME}.xml"
+ testSuiteName = "[MCP] Integration automation"
+ methodname = '{methodname}'
+ testrail_name_template = '{title}'
+ reporter_extra_options = [
+ "--testrail-add-missing-cases",
+ "--testrail-case-custom-fields {\\\"custom_qa_team\\\":\\\"9\\\"}",
+ "--testrail-case-section-name \'All\'",
+ ]
+ shared.upload_results_to_testrail(deployment_report_name, testSuiteName, methodname, testrail_name_template, reporter_extra_options)
}
}
- if ('k8s' in stacks) {
+ if (tcpqa_report_name) {
+ stage("tcp-qa cases report") {
+// report_name = "nosetests.xml"
+ testSuiteName = "[MCP_X] integration cases"
+ methodname = "{methodname}"
+ testrail_name_template = "{title}"
+ reporter_extra_options = [
+ "--testrail-add-missing-cases",
+ "--testrail-case-custom-fields {\\\"custom_qa_team\\\":\\\"9\\\"}",
+ "--testrail-case-section-name \'All\'",
+ ]
+ shared.upload_results_to_testrail(tcpqa_report_name, testSuiteName, methodname, testrail_name_template, reporter_extra_options)
+ }
+ }
+
+ if ('openstack' in stacks && tempest_report_name) {
stage("Tempest report") {
+// report_name = "report_*.xml"
+ testSuiteName = "[MCP1.1_PIKE]Tempest"
+ methodname = "{classname}.{methodname}"
+ testrail_name_template = "{title}"
+ shared.upload_results_to_testrail(tempest_report_name, testSuiteName, methodname, testrail_name_template)
+ }
+ }
+
+ if ('k8s' in stacks && k8s_conformance_report_name) {
+ stage("K8s conformance report") {
println "TBD"
// K8s conformance report
}
}
- if ('stacklight' in stacks) {
+ if ('stacklight' in stacks && stacklight_report_name) {
stage("stacklight-pytest report") {
- report_name = "report.xml"
+// report_name = "stacklight_report.xml"
testSuiteName = "LMA2.0_Automated"
methodname = "{methodname}"
testrail_name_template = "{title}"
- shared.upload_results_to_testrail(report_name, testSuiteName, methodname, testrail_name_template)
+ shared.upload_results_to_testrail(stacklight_report_name, testSuiteName, methodname, testrail_name_template)
}
}
diff --git a/src/com/mirantis/system_qa/SharedPipeline.groovy b/src/com/mirantis/system_qa/SharedPipeline.groovy
index 775b901..e4779cd 100644
--- a/src/com/mirantis/system_qa/SharedPipeline.groovy
+++ b/src/com/mirantis/system_qa/SharedPipeline.groovy
@@ -117,6 +117,13 @@
def swarm_bootstrap_salt_cluster_devops() {
def common = new com.mirantis.mk.Common()
+ def cookiecutter_template_commit = env.COOKIECUTTER_TEMPLATE_COMMIT ?: env.MCP_VERSION
+ def salt_models_system_commit = env.SALT_MODELS_SYSTEM_COMMIT ?: env.MCP_VERSION
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
+ def mk_pipelines_ref = env.MK_PIPELINES_REF ?: ''
+ def pipeline_library_ref = env.PIPELINE_LIBRARY_REF ?: ''
+ def cookiecutter_ref_change = env.COOKIECUTTER_REF_CHANGE ?: ''
+ def environment_template_ref_change = env.ENVIRONMENT_TEMPLATE_REF_CHANGE ?: ''
def parameters = [
string(name: 'PARENT_NODE_NAME', value: "${NODE_NAME}"),
string(name: 'PARENT_WORKSPACE', value: pwd()),
@@ -126,11 +133,13 @@
string(name: 'MCP_IMAGE_PATH1604', value: "${MCP_IMAGE_PATH1604}"),
string(name: 'IMAGE_PATH_CFG01_DAY01', value: "${IMAGE_PATH_CFG01_DAY01}"),
string(name: 'CFG01_CONFIG_IMAGE_NAME', value: "${CFG01_CONFIG_IMAGE_NAME}"),
- string(name: 'TCP_QA_REFS', value: "${TCP_QA_REFS}"),
- string(name: 'PIPELINE_LIBRARY_REF', value: "${PIPELINE_LIBRARY_REF}"),
- string(name: 'MK_PIPELINES_REF', value: "${MK_PIPELINES_REF}"),
- string(name: 'COOKIECUTTER_TEMPLATE_COMMIT', value: "${COOKIECUTTER_TEMPLATE_COMMIT}"),
- string(name: 'SALT_MODELS_SYSTEM_COMMIT', value: "${SALT_MODELS_SYSTEM_COMMIT}"),
+ string(name: 'TCP_QA_REFS', value: "${tcp_qa_refs}"),
+ string(name: 'PIPELINE_LIBRARY_REF', value: "${pipeline_library_ref}"),
+ string(name: 'MK_PIPELINES_REF', value: "${mk_pipelines_ref}"),
+ string(name: 'COOKIECUTTER_TEMPLATE_COMMIT', value: "${cookiecutter_template_commit}"),
+ string(name: 'SALT_MODELS_SYSTEM_COMMIT', value: "${salt_models_system_commit}"),
+ string(name: 'COOKIECUTTER_REF_CHANGE', value: "${cookiecutter_ref_change}"),
+ string(name: 'ENVIRONMENT_TEMPLATE_REF_CHANGE', value: "${environment_template_ref_change}"),
booleanParam(name: 'SHUTDOWN_ENV_ON_TEARDOWN', value: false),
]
@@ -140,12 +149,13 @@
def swarm_deploy_cicd(String stack_to_install='core,cicd') {
// Run openstack_deploy job on cfg01 Jenkins for specified stacks
def common = new com.mirantis.mk.Common()
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
def parameters = [
string(name: 'PARENT_NODE_NAME', value: "${NODE_NAME}"),
string(name: 'PARENT_WORKSPACE', value: pwd()),
string(name: 'ENV_NAME', value: "${ENV_NAME}"),
string(name: 'STACK_INSTALL', value: stack_to_install),
- string(name: 'TCP_QA_REFS', value: "${TCP_QA_REFS}"),
+ string(name: 'TCP_QA_REFS', value: "${tcp_qa_refs}"),
booleanParam(name: 'SHUTDOWN_ENV_ON_TEARDOWN', value: false),
]
build_pipeline_job('swarm-deploy-cicd', parameters)
@@ -154,12 +164,13 @@
def swarm_deploy_platform(String stack_to_install) {
// Run openstack_deploy job on CICD Jenkins for specified stacks
def common = new com.mirantis.mk.Common()
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
def parameters = [
string(name: 'PARENT_NODE_NAME', value: "${NODE_NAME}"),
string(name: 'PARENT_WORKSPACE', value: pwd()),
string(name: 'ENV_NAME', value: "${ENV_NAME}"),
string(name: 'STACK_INSTALL', value: stack_to_install),
- string(name: 'TCP_QA_REFS', value: "${TCP_QA_REFS}"),
+ string(name: 'TCP_QA_REFS', value: "${tcp_qa_refs}"),
booleanParam(name: 'SHUTDOWN_ENV_ON_TEARDOWN', value: false),
]
build_pipeline_job('swarm-deploy-platform', parameters)
@@ -168,13 +179,14 @@
def swarm_run_pytest(String passed_steps) {
// Run pytest tests
def common = new com.mirantis.mk.Common()
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
def parameters = [
string(name: 'ENV_NAME', value: "${ENV_NAME}"),
string(name: 'PASSED_STEPS', value: passed_steps),
string(name: 'RUN_TEST_OPTS', value: "${RUN_TEST_OPTS}"),
string(name: 'PARENT_NODE_NAME', value: "${NODE_NAME}"),
string(name: 'PARENT_WORKSPACE', value: pwd()),
- string(name: 'TCP_QA_REFS', value: "${TCP_QA_REFS}"),
+ string(name: 'TCP_QA_REFS', value: "${tcp_qa_refs}"),
booleanParam(name: 'SHUTDOWN_ENV_ON_TEARDOWN', value: false),
string(name: 'LAB_CONFIG_NAME', value: "${LAB_CONFIG_NAME}"),
string(name: 'REPOSITORY_SUITE', value: "${MCP_VERSION}"),
@@ -190,13 +202,14 @@
def swarm_testrail_report(String passed_steps) {
// Run pytest tests
def common = new com.mirantis.mk.Common()
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
def parameters = [
string(name: 'ENV_NAME', value: "${ENV_NAME}"),
string(name: 'MCP_VERSION', value: "${MCP_VERSION}"),
string(name: 'PASSED_STEPS', value: passed_steps),
string(name: 'PARENT_NODE_NAME', value: "${NODE_NAME}"),
string(name: 'PARENT_WORKSPACE', value: pwd()),
- string(name: 'TCP_QA_REFS', value: "${TCP_QA_REFS}"),
+ string(name: 'TCP_QA_REFS', value: "${tcp_qa_refs}"),
]
common.printMsg("Start building job 'swarm-testrail-report' with parameters:", "purple")
common.prettyPrint(parameters)
@@ -218,6 +231,9 @@
def cookiecuttertemplate_commit = env.COOKIECUTTER_TEMPLATE_COMMIT ?: env.MCP_VERSION
def saltmodels_system_commit = env.SALT_MODELS_SYSTEM_COMMIT ?: env.MCP_VERSION
+ def tcp_qa_refs = env.TCP_QA_REFS ?: ''
+ def environment_template_ref_change = env.ENVIRONMENT_TEMPLATE_REF_CHANGE ?: ''
+ def cookiecutter_ref_change = env.COOKIECUTTER_REF_CHANGE ?: ''
def parameters = [
string(name: 'LAB_CONTEXT_NAME', value: "${LAB_CONFIG_NAME}"),
@@ -226,7 +242,9 @@
string(name: 'REPOSITORY_SUITE', value: "${env.MCP_VERSION}"),
string(name: 'SALT_MODELS_SYSTEM_COMMIT', value: "${saltmodels_system_commit}"),
string(name: 'COOKIECUTTER_TEMPLATE_COMMIT', value: "${cookiecuttertemplate_commit}"),
- string(name: 'TCP_QA_REVIEW', value: "${TCP_QA_REFS}"),
+ string(name: 'COOKIECUTTER_REF_CHANGE', value: "${cookiecutter_ref_change}"),
+ string(name: 'ENVIRONMENT_TEMPLATE_REF_CHANGE', value: "${environment_template_ref_change}"),
+ string(name: 'TCP_QA_REVIEW', value: "${tcp_qa_refs}"),
string(name: 'IPV4_NET_ADMIN', value: IPV4_NET_ADMIN),
string(name: 'IPV4_NET_CONTROL', value: IPV4_NET_CONTROL),
string(name: 'IPV4_NET_TENANT', value: IPV4_NET_TENANT),
@@ -244,6 +262,10 @@
echo \$SALT_MASTER_IP
""").trim().split().last()
println("SALT_MASTER_IP=" + SALT_MASTER_IP)
+
+ def mk_pipelines_ref = env.MK_PIPELINES_REF ?: ''
+ def pipeline_library_ref = env.PIPELINE_LIBRARY_REF ?: ''
+
def parameters = [
string(name: 'CLUSTER_NAME', value: "${LAB_CONFIG_NAME}"),
string(name: 'MODEL_URL', value: "http://cz8133.bud.mirantis.net:8098/${LAB_CONFIG_NAME}.git"),
@@ -258,8 +280,8 @@
booleanParam(name: 'PIPELINES_FROM_ISO', value: true),
string(name: 'MCP_SALT_REPO_URL', value: "http://apt.mirantis.com/xenial"),
string(name: 'MCP_SALT_REPO_KEY', value: "http://apt.mirantis.com/public.gpg"),
- string(name: 'PIPELINE_LIBRARY_REF', value: "${PIPELINE_LIBRARY_REF}"),
- string(name: 'MK_PIPELINES_REF', value: "${MK_PIPELINES_REF}"),
+ string(name: 'PIPELINE_LIBRARY_REF', value: "${pipeline_library_ref}"),
+ string(name: 'MK_PIPELINES_REF', value: "${mk_pipelines_ref}"),
]
build_pipeline_job('create-cfg-config-drive', parameters)
}
@@ -347,11 +369,15 @@
// then make a copy for the created snapshot to allow the system
// tests to revert this snapshot along with the metadata from the INI file.
run_cmd("""\
+ set -ex
dos.py suspend ${ENV_NAME}
dos.py snapshot ${ENV_NAME} ${stack}_deployed
dos.py resume ${ENV_NAME}
sleep 20 # Wait for I/O on the host calms down
- dos.py time-sync ${ENV_NAME} || dos.py time-sync ${ENV_NAME} # sometimes, timesync may fail. Need to update it in fuel-devops.
+
+ CFG01_NAME=\$(dos.py show-resources ${ENV_NAME} | grep ^cfg01 | cut -d" " -f1)
+ dos.py time-sync ${ENV_NAME} --skip-sync \${CFG01_NAME}
+
if [ -f \$(pwd)/${ENV_NAME}_salt_deployed.ini ]; then
cp \$(pwd)/${ENV_NAME}_salt_deployed.ini \$(pwd)/${ENV_NAME}_${stack}_deployed.ini
fi
@@ -408,10 +434,7 @@
def script = """
. ${venvPath}/bin/activate
set -ex
- report_xml=\$(find ${PARENT_WORKSPACE} -name "${report_name}")
- if [ -n "\${report_xml}" ]; then
- report ${reporterOptions.join(' ')} \${report_xml}
- fi
+ report ${reporterOptions.join(' ')} ${report_name}
"""
def testrail_cred_id = params.TESTRAIL_CRED ?: 'testrail_system_tests'
diff --git a/tcp_tests/fixtures/ceph_fixtures.py b/tcp_tests/fixtures/ceph_fixtures.py
index 44ab7d2..a06965b 100644
--- a/tcp_tests/fixtures/ceph_fixtures.py
+++ b/tcp_tests/fixtures/ceph_fixtures.py
@@ -22,7 +22,7 @@
@pytest.fixture(scope='function')
-def ceph_actions(config, underlay, salt_deployed):
+def ceph_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for OpenStack
:param config: fixture provides oslo.config
@@ -32,7 +32,7 @@
For use in tests or fixtures to deploy a custom OpenStack
"""
- return ceph_manager.CephManager(config, underlay, salt_deployed)
+ return ceph_manager.CephManager(config, underlay_actions, salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.ceph_deployed)
diff --git a/tcp_tests/fixtures/core_fixtures.py b/tcp_tests/fixtures/core_fixtures.py
index cb058a3..98f88c2 100644
--- a/tcp_tests/fixtures/core_fixtures.py
+++ b/tcp_tests/fixtures/core_fixtures.py
@@ -22,14 +22,14 @@
@pytest.fixture(scope='function')
-def core_actions(config, underlay, salt_actions):
+def core_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for Core
:param config: fixture provides oslo.config
:param underlay: fixture provides underlay manager
:rtype: CoreManager
"""
- return core_manager.CoreManager(config, underlay, salt_actions)
+ return core_manager.CoreManager(config, underlay_actions, salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.core_deployed)
diff --git a/tcp_tests/fixtures/decapod_fixtures.py b/tcp_tests/fixtures/decapod_fixtures.py
index 8e40b41..0ef8869 100644
--- a/tcp_tests/fixtures/decapod_fixtures.py
+++ b/tcp_tests/fixtures/decapod_fixtures.py
@@ -22,14 +22,15 @@
@pytest.fixture(scope='function')
-def decapod_actions(config, underlay, salt_actions):
+def decapod_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for Decapod
:param config: fixture provides oslo.config
:param underlay: fixture provides underlay manager
:rtype: DecapodManager
"""
- return decapod_manager.DecapodManager(config, underlay, salt_actions)
+ return decapod_manager.DecapodManager(config, underlay_actions,
+ salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.decapod_deployed)
diff --git a/tcp_tests/fixtures/drivetrain_fixtures.py b/tcp_tests/fixtures/drivetrain_fixtures.py
index e0e709b..0e8cbed 100644
--- a/tcp_tests/fixtures/drivetrain_fixtures.py
+++ b/tcp_tests/fixtures/drivetrain_fixtures.py
@@ -22,14 +22,15 @@
@pytest.fixture(scope='function')
-def drivetrain_actions(config, underlay, salt_actions):
+def drivetrain_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for Drivetrain
:param config: fixture provides oslo.config
:param underlay: fixture provides underlay manager
:rtype: DrivetrainManager
"""
- return drivetrain_manager.DrivetrainManager(config, underlay, salt_actions)
+ return drivetrain_manager.DrivetrainManager(config, underlay_actions,
+ salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.drivetrain_deployed)
diff --git a/tcp_tests/fixtures/k8s_fixtures.py b/tcp_tests/fixtures/k8s_fixtures.py
index fee64cf..e581b86 100644
--- a/tcp_tests/fixtures/k8s_fixtures.py
+++ b/tcp_tests/fixtures/k8s_fixtures.py
@@ -24,7 +24,7 @@
@pytest.fixture(scope='function')
-def k8s_actions(config, underlay, salt_deployed):
+def k8s_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for K8S
:param config: fixture provides oslo.config
@@ -34,7 +34,7 @@
For use in tests or fixtures to deploy a custom K8S
"""
- return k8smanager.K8SManager(config, underlay, salt_deployed)
+ return k8smanager.K8SManager(config, underlay_actions, salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.k8s_deployed)
@@ -107,7 +107,7 @@
@pytest.fixture(scope='function')
-def k8s_logs(request, func_name, underlay, k8s_deployed):
+def k8s_logs(request, func_name, k8s_actions):
"""Finalizer to extract conformance logs
Usage:
@@ -156,16 +156,16 @@
files_to_extract = utils.extract_name_from_mark(
extract, 'files_to_extract')
for path in files_to_extract:
- k8s_deployed.extract_file_to_node(
+ k8s_actions.extract_file_to_node(
system=container_system, container=extract_from,
file_path=path)
else:
- k8s_deployed.extract_file_to_node()
+ k8s_actions.extract_file_to_node()
if merge_xunit:
path = utils.extract_name_from_mark(merge_xunit, 'path')
output = utils.extract_name_from_mark(merge_xunit, 'output')
- k8s_deployed.combine_xunit(path, output)
- k8s_deployed.download_k8s_logs(files)
+ k8s_actions.combine_xunit(path, output)
+ k8s_actions.download_k8s_logs(files)
request.addfinalizer(test_fin)
diff --git a/tcp_tests/fixtures/openstack_fixtures.py b/tcp_tests/fixtures/openstack_fixtures.py
index 480a548..e3f8780 100644
--- a/tcp_tests/fixtures/openstack_fixtures.py
+++ b/tcp_tests/fixtures/openstack_fixtures.py
@@ -22,7 +22,7 @@
@pytest.fixture(scope='function')
-def openstack_actions(config, underlay, salt_deployed):
+def openstack_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for OpenStack
:param config: fixture provides oslo.config
@@ -33,7 +33,8 @@
For use in tests or fixtures to deploy a custom OpenStack
"""
- return openstack_manager.OpenstackManager(config, underlay, salt_deployed)
+ return openstack_manager.OpenstackManager(config, underlay_actions,
+ salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.openstack_deployed)
diff --git a/tcp_tests/fixtures/oss_fixtures.py b/tcp_tests/fixtures/oss_fixtures.py
index 6162e27..3ff12f1 100644
--- a/tcp_tests/fixtures/oss_fixtures.py
+++ b/tcp_tests/fixtures/oss_fixtures.py
@@ -22,14 +22,14 @@
@pytest.fixture(scope='function')
-def oss_actions(config, underlay, salt_actions):
+def oss_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for OSS
:param config: fixture provides oslo.config
:param underlay: fixture provides underlay manager
:rtype: OSSManager
"""
- return oss_manager.OSSManager(config, underlay, salt_actions)
+ return oss_manager.OSSManager(config, underlay_actions, salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.oss_deployed)
diff --git a/tcp_tests/fixtures/runtest_fixtures.py b/tcp_tests/fixtures/runtest_fixtures.py
index 4609915..5a5c09e 100644
--- a/tcp_tests/fixtures/runtest_fixtures.py
+++ b/tcp_tests/fixtures/runtest_fixtures.py
@@ -18,7 +18,7 @@
@pytest.fixture(scope='function')
-def tempest_actions(underlay, salt_actions):
+def tempest_actions(underlay_actions, salt_actions):
"""
Run tempest tests
"""
@@ -29,7 +29,7 @@
domain_name = settings.DOMAIN_NAME
target = settings.TEMPEST_TARGET
runtest = RuntestManager(
- underlay, salt_actions,
+ underlay_actions, salt_actions,
cluster_name=cluster_name,
domain_name=domain_name,
tempest_threads=tempest_threads,
diff --git a/tcp_tests/fixtures/salt_fixtures.py b/tcp_tests/fixtures/salt_fixtures.py
index 469b965..7f4ce60 100644
--- a/tcp_tests/fixtures/salt_fixtures.py
+++ b/tcp_tests/fixtures/salt_fixtures.py
@@ -22,14 +22,14 @@
@pytest.fixture(scope='function')
-def salt_actions(config, underlay):
+def salt_actions(config, underlay_actions):
"""Fixture that provides various actions for salt
:param config: fixture provides oslo.config
:param underlay: fixture provides underlay manager
:rtype: SaltManager
"""
- return saltmanager.SaltManager(config, underlay)
+ return saltmanager.SaltManager(config, underlay_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.salt_deployed)
diff --git a/tcp_tests/fixtures/stacklight_fixtures.py b/tcp_tests/fixtures/stacklight_fixtures.py
index df0d516..4340847 100644
--- a/tcp_tests/fixtures/stacklight_fixtures.py
+++ b/tcp_tests/fixtures/stacklight_fixtures.py
@@ -23,7 +23,7 @@
@pytest.fixture(scope='function')
-def sl_actions(config, underlay, salt_deployed):
+def sl_actions(config, underlay_actions, salt_actions):
"""Fixture that provides various actions for K8S
:param config: fixture provides oslo.config
@@ -32,14 +32,14 @@
For use in tests or fixtures to deploy a custom K8S
"""
- return sl_manager.SLManager(config, underlay, salt_deployed)
+ return sl_manager.SLManager(config, underlay_actions, salt_actions)
@pytest.mark.revert_snapshot(ext.SNAPSHOT.stacklight_deployed)
@pytest.fixture(scope='function')
def stacklight_deployed(revert_snapshot, request, config,
- hardware, underlay, core_deployed,
- salt_deployed, sl_actions):
+ hardware, underlay, salt_deployed,
+ sl_actions, core_deployed):
"""Fixture to get or install SL services on environment
:param revert_snapshot: fixture that reverts snapshot that is specified
diff --git a/tcp_tests/managers/k8smanager.py b/tcp_tests/managers/k8smanager.py
index a72f2f1..a4c22ca 100644
--- a/tcp_tests/managers/k8smanager.py
+++ b/tcp_tests/managers/k8smanager.py
@@ -332,7 +332,7 @@
LOG.debug('Installing xunitmerge')
r.check_call(cmd, raise_on_err=False)
LOG.debug('Merging xunit')
- cmd = ("cd {0}; arg = ''; "
+ cmd = ("cd {0}; arg=''; "
"for i in $(ls | grep xml); "
"do arg=\"$arg $i\"; done && "
"xunitmerge $arg {1}".format(path, output))
diff --git a/tcp_tests/managers/sl_manager.py b/tcp_tests/managers/sl_manager.py
index 2c1ba2d..3bb0a1f 100644
--- a/tcp_tests/managers/sl_manager.py
+++ b/tcp_tests/managers/sl_manager.py
@@ -19,6 +19,7 @@
from tcp_tests.managers.execute_commands import ExecuteCommandsMixin
from tcp_tests.managers.clients.prometheus import prometheus_client
from tcp_tests import logger
+from tcp_tests import settings
LOG = logger.logger
@@ -97,17 +98,65 @@
service_stat_dict.update({tmp[0]: tmp[1]})
return service_stat_dict
- def run_sl_functional_tests(self, node_to_run, tests_path,
- test_to_run, skip_tests,
- reruns=5, reruns_delay=60):
+ def setup_sl_functional_tests(self, node_to_run,
+ repo_path='/root/stacklight-pytest',
+ sl_test_repo=settings.SL_TEST_REPO,
+ sl_test_commit=settings.SL_TEST_COMMIT):
target_node_name = [node_name for node_name
in self.__underlay.node_names()
if node_to_run in node_name]
- cmd = (". venv-stacklight-pytest/bin/activate;"
+ cmd_install = (
+ "set -ex;"
+ "apt-get install -y build-essential python-dev "
+ " virtualenv;"
+ "[ -d venv-stacklight-pytest ] || "
+ " virtualenv --system-site-packages venv-stacklight-pytest;"
+ ". venv-stacklight-pytest/bin/activate;"
+ "if [ ! -d {repo_path} ]; then"
+ " git clone {sl_test_repo} {repo_path};"
+ "fi;"
+ "pushd {repo_path};"
+ "git checkout {sl_test_commit};"
+ "popd;"
+ "pip install {repo_path};"
+ .format(repo_path=repo_path,
+ sl_test_repo=sl_test_repo,
+ sl_test_commit=sl_test_commit)
+ )
+
+ cmd_configure = (
+ "set -ex;"
+ ". venv-stacklight-pytest/bin/activate;"
+ "stl-tests gen-config-mk;"
+ "cp venv-stacklight-pytest/lib/python2.7/site-packages/"
+ "stacklight_tests/fixtures/config.yaml "
+ "{repo_path}/stacklight_tests/fixtures/config.yaml;"
+ .format(repo_path=repo_path)
+ )
+
+ with self.__underlay.remote(node_name=target_node_name[0]) \
+ as node_remote:
+ LOG.info("Install stacklight-pytest on the node {0}".format(
+ target_node_name[0]))
+ node_remote.check_call(cmd_install, verbose=True)
+
+ LOG.info("Configure stacklight-pytest on the node {0}".format(
+ target_node_name[0]))
+ node_remote.check_call(cmd_configure, verbose=True)
+
+ def run_sl_functional_tests(self, node_to_run, tests_path,
+ test_to_run, skip_tests,
+ reruns=5, reruns_delay=60,
+ junit_report_name='report.xml'):
+ target_node_name = [node_name for node_name
+ in self.__underlay.node_names()
+ if node_to_run in node_name]
+ cmd = ("set -ex;"
+ ". venv-stacklight-pytest/bin/activate;"
"cd {tests_path}; "
"export VOLUME_STATUS='available';"
- "pytest {reruns} {reruns_delay} "
- "-k {skip_tests} {test_to_run}".format(**{
+ "pytest {reruns} {reruns_delay} --junit-xml={junit_report_name}"
+ " -k {skip_tests} {test_to_run}".format(**{
"tests_path": tests_path,
"skip_tests": ("'not " + skip_tests + "'"
if skip_tests else ''),
@@ -116,6 +165,7 @@
if reruns > 1 else ""),
"reruns_delay": ("--reruns-delay {}".format(reruns_delay)
if reruns_delay > 0 else ""),
+ "junit_report_name": junit_report_name,
}))
with self.__underlay.remote(node_name=target_node_name[0]) \
@@ -131,7 +181,8 @@
target_node_name = [node_name for node_name
in self.__underlay.node_names()
if node_to_run in node_name]
- cmd = (". venv-stacklight-pytest/bin/activate;"
+ cmd = ("set -ex;"
+ ". venv-stacklight-pytest/bin/activate;"
"cd {tests_path}; "
"export VOLUME_STATUS='available';"
"pip install pytest-json;"
diff --git a/tcp_tests/requirements.txt b/tcp_tests/requirements.txt
index 8233a9b..83461ab 100644
--- a/tcp_tests/requirements.txt
+++ b/tcp_tests/requirements.txt
@@ -1,6 +1,6 @@
# git+git://github.com/openstack/fuel-devops.git@887368d#egg=project[postgre] # Use this requirement for PostgreSQL
libvirt-python>=3.5.0,<4.1.0 # LGPLv2+
-git+git://github.com/openstack/fuel-devops.git@25d4cc67315132b1b27131977b2e07029b3ffbe1 # Use this requirement for Sqlite3, or if requirements for PostgreSQL are already installed
+git+git://github.com/openstack/fuel-devops.git@10f4ac744e89bfefcba3d7d009de82669c52fa6e # Use this requirement for Sqlite3, or if requirements for PostgreSQL are already installed
git+git://github.com/dis-xcom/fuel-devops-driver-ironic
paramiko
six
diff --git a/tcp_tests/settings.py b/tcp_tests/settings.py
index fcbe1a9..9ddabd7 100644
--- a/tcp_tests/settings.py
+++ b/tcp_tests/settings.py
@@ -84,3 +84,7 @@
'--blacklist-file mcp_pike_lvm_skip.list')
TEMPEST_TARGET = os.environ.get('TEMPEST_TARGET', 'gtw01')
SALT_VERSION = os.environ.get('SALT_VERSION', '2017.7')
+
+SL_TEST_REPO = os.environ.get('SL_TEST_REPO',
+ 'https://github.com/Mirantis/stacklight-pytest')
+SL_TEST_COMMIT = os.environ.get('SL_TEST_COMMIT', 'master')
diff --git a/tcp_tests/templates/cookied-cicd-k8s-calico-sl/cookiecutter-context-k8s-sl.yaml b/tcp_tests/templates/cookied-cicd-k8s-calico-sl/cookiecutter-context-k8s-sl.yaml
index 898017e..fff58d3 100644
--- a/tcp_tests/templates/cookied-cicd-k8s-calico-sl/cookiecutter-context-k8s-sl.yaml
+++ b/tcp_tests/templates/cookied-cicd-k8s-calico-sl/cookiecutter-context-k8s-sl.yaml
@@ -1,34 +1,34 @@
default_context:
auditd_enabled: 'False'
- backup_private_key: |-
- -----BE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VWVuAqzVbRjyGp
- yddGiW2Q+ITdfPfHbCFobVUgFeSinfZxkMFw4g0CgYBG8rZASzJU+W8CdXq24ukS
- ezYzUbIGTt4gJlry9Q8ysEM+NYpilkkcrg4AaMd1gy2zxinmNr0KZ4BWKywWvRRT
- x6BCB7cTyKRZ0KTnhqv40dSyoyQRy75a2oLCHRCVbw7fCarOC5I34UjVvTCWhipK
- C9+FJm8z954+T/Fr5SANFwKBgEJBSvhD2jBRn5ckjY7My9SZD30Mkj9gTlOjU7vF
- /CWCi+vvD+NkgfIrU6bi1S/uwx94UC4zJhSGWHNYZBuhHSREour65J2X5zJZJwA3
- RyXaVsSWdPRoeahiMV6vd2R5NXkGOcHZEEGcrbSjNUlJ4DWwETbYEf+CI3VhM67T
- MihZAoGBALxcTSivHJZDle81lsu1dcgmzZkUfQAcUSYDWhg+Bqg3A8FVKMpEzrbd
- weGRM8S8oAz1PN0T/LRcpJq3TFZpy+iXx59jl5XenmoKwPr+u5XFrEHTWqNS2NcL
- MwS8VTJhWYNVdrNIRWClRVUv87hZMha40JHiPK1KA4em1G+H29x3
- -----END RSA PRIVATE KEY-----
- backup_public_key: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC3IJ+JfHAHoOTqftjW327ZeoyQs+8wCsrBFRYYTBPNLvDQ3NhsJh1R/Gj2be2aEI7qFvRirOTosRw6sBFHuccrt1LQmlGZkF4Pe2F2BcPzA1obU9BnN03AYc/lyN8Fc8dhd0/WToe0sHU/KY8PISqFTRkmtUYErj5ZIs16xIY4yJERBLGSD/zloZ1qAtYeABuCLTHXHH4G7wu25WQhzPwgxreVqdjsHyzlogzGw4ZOiQm91EtBkk3QB8ZFIA1MhBld+CRM7nA/zlSw2KwHyPtuWIuXXBvGCer8tMln6dDU8Dh3Hxy3QUodghHrNJ3QuQNlrEmdkGBKtWdnYkFu3uFP
+ backup_private_key: |
+ -----BEGIN RSA PRIVATE KEY-----
+ MIIEowIBAAKCAQEAxL6/rVgCetsETpZaUm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AoGADCd8wDb9bPhP/LQqBmIX
+ ylXmwHHisaxE9O/wUQT4bwREjGd25gv6c9wkkRx8LBsLsGs9hzI7dMOL9Ly+2x9l
+ SvqmsC3S/1zl77X1Ir2/Z57MT6Vgo1xBmtnZU3Rhz2/eKAdqFPNLClaZrgGT475N
+ HcyLLWMzR0IJFtabY+Puea0CgYA8Zb5wRkldxWLewSuJZZDinGwY+kieAVjLJq/K
+ 0j+ah6fQ48LXcah0wpIgz+cMjHcUO9GWQdk3/x9X03rqX5EL2DBnZYfUIl63F9zj
+ M97ZkHOSNWVqPzX//0Vv2butewG0j3jZKfTo/2/SrxOYgEpYtC9huWpSVi7xm0US
+ erhSkQKBgFIf9JEsfgE57ANhvITZ3ZI0uZXNxZkXQaVg8jvScDi79IIhy9iPzhKC
+ aIIQoDNIlWv1ftCRZ5AlBvVXgvQ/QNrwy48JiQTzWZlb9Ezg8w+olQmSbG6fq7Y+
+ 7r3i+QUZ7RBdOb24QcQ618q54ozNTCB7OywY78ptFzeoBeptiNr1
+ -----END RSA PRIVATE KEY-----
+ backup_public_key: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDEvr+tWAJ62wROllpSZeaSPxxnVY3R65sfUW8wM6L8tr1knJOTQLoBikmcjISb3ekyPlwubTypGoxb7al06FiNwfr3KDkytflKRGTyMKYgchighuFCfBuePd13cjf1l19TYU7u7a+VuCVWi7pmhDGUkMi24s23OroQb7D14XX17v46wLrqJQi2nrXzN/DWXcn/ycq8IZ7ZFgN/uYlbpfAKX8PCvImbDDO8+BgndAy4MPz8cWOWsnfGMVNePhvhazVcijLvx8Vu2Iuvg7CoJiSGjTe7YTms44/WpnFkHreyK8cwsw4wzls4BApu6UU2jIAsAMZh9zux/Rtni71dcNfF
bmk_enabled: 'False'
calico_cni_image: docker-prod-local.artifactory.mirantis.com/mirantis/projectcalico/calico/cni:latest
calico_enable_nat: 'True'
diff --git a/tcp_tests/templates/cookied-cicd-k8s-calico/cookiecutter-context-k8s.yaml b/tcp_tests/templates/cookied-cicd-k8s-calico/cookiecutter-context-k8s.yaml
index 2f0e52e..9b2c7d9 100644
--- a/tcp_tests/templates/cookied-cicd-k8s-calico/cookiecutter-context-k8s.yaml
+++ b/tcp_tests/templates/cookied-cicd-k8s-calico/cookiecutter-context-k8s.yaml
@@ -1,34 +1,34 @@
default_context:
auditd_enabled: 'False'
- backup_private_key: |-
- -----BEGIN RSA PRIVATE KEY-----
- MIIEpAIBAAKCAQEA3ufjR+Eh/CJp84JZPKosMNL7ydXidfe9qdAnQIGGOsS/TBnc
- RyY+hy4Mg5Or//VBpY53frcrEEnm1CzEeIfGALiQtsMWOwEEiEHIDzbxN7xyYK1u
- 9fpcRHZy16VJx2gQOxbeAIyct9jrQeQuSbN0k7Tr+bfWLVPoGL4SZiBC+dxRjrmT
- 2pMIdqa8kAcd5cakuyENXT31ZI/ffVscl7TJBat7tUbgD+48GK4LqMBL/eC6v2bQ
- ohmo6ZqWLh9uT+/l/rRdIiBhI+kmPpUDRLnjkd/gH4GQh/r/PPlxu11JNwPgY4Kx
- IAk5hq9uPRn3pqBKPg+WHgWmQvpHqVVDDnf7XQIDAQABAoIBAQDCEtuL5bQVNlFR
- NphDfVZkXA3lOVempkB37Ud/nkYkPNDhjVKAkAe44pr6pEQI4px5bIUVypyv3egf
- q6qT1oLKdedpeImObeBoUf3BYXC7ulNLYTVO7OAQq6BpqPuHpk8bY1l+2O5KE48h
- G25BtQE26TrbfPf5FyjpAfQ6/rPRniURu1ZMFK1Do18wf7lGxa6RN4jPbfGfEvlf
- q6GWGtsOB2kLXnUDjuDeUrgS8HgxBSMH+lwxrkdX0Qb4VN+cBOp8TC30rHXdLAmn
- mWUDQhaao+zZpZsAAxGbM2BAFUQAicd/OS6FJn6xkH0KN6+Rp1Iiy3Sa97wMsMti
- aHAyVwkBAoGBAPf1gcRmKTHaUVb7XgS3acytBm7LM2GCQfgPDvQIp8rf8bmnAko6
- MzxPdq2WXzWY75JiNxQSsmemcJyBRJm1ssc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vhazVcijLvx8Vu2Iuvg7CoJiSGjTe7YTms44/WpnFkHreyK8cwsw4wzls4BApu6UU2jIAsAMZh9zux/Rtni71dcNfF
bmk_enabled: 'False'
calico_cni_image: docker-prod-local.artifactory.mirantis.com/mirantis/projectcalico/calico/cni:latest
calico_enable_nat: 'True'
diff --git a/tcp_tests/templates/cookied-cicd-k8s-genie/cookiecutter-context-k8s-genie.yaml b/tcp_tests/templates/cookied-cicd-k8s-genie/cookiecutter-context-k8s-genie.yaml
index 48e91fd..a1b22be 100644
--- a/tcp_tests/templates/cookied-cicd-k8s-genie/cookiecutter-context-k8s-genie.yaml
+++ b/tcp_tests/templates/cookied-cicd-k8s-genie/cookiecutter-context-k8s-genie.yaml
@@ -1,34 +1,34 @@
default_context:
auditd_enabled: 'False'
- backup_private_key: |-
- -----BEGIN RSA PRIVATE KEY-----
- MIIEowIBAAKCAQEAtyCfiXxwB6Dk6n7Y1t9u2XqMkLPvMArKwRUWGEwTzS7w0NzY
- bCYdUfxo9m3tmhCO6hb0Yqzk6LEcOrARR7nHK7dS0JpRmZBeD3thdgXD8wNaG1PQ
- ZzdNwGHP5cjfBXPHYXdP1k6HtLB1PymPDyEqhU0ZJrVGBK4+WSLNesSGOMiREQSx
- kg/85aGdagLWHgAbgi0x1xx+Bu8LtuVkIcz8IMa3lanY7B8s5aIMxsOGTokJvdRL
- QZJN0AfGRSANTIQZXfgkTO5wP85UsNisB8j7bliLl1wbxgnq/LTJZ+nQ1PA4dx8c
- t0FKHYIR6zSd0LkDZaxJnZBgSrVnZ2JBbt7hTwIDAQABAoIBAHu/Ic+INTQSd142
- hVT9+ywe8em+jX0LbeN32kxk7GSUucqJ0f2S6/FA/bS4p/yZ/9kT1eTwLGdJd2f5
- HlQ3p+1UnjO0dDuvIMCZgUx9rOIEe9lHk+aLqpC8B/6g9IP8rtigBWUt/+oL687Y
- yIFSyib16G8Nw9jZ3evh5rR1JLYtPHvAJiodsT3iY/+wZkuo4dAa4/QlKPT7QXaU
- G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wROllpSZeaSPxxnVY3R65sfUW8wM6L8tr1knJOTQLoBikmcjISb3ekyPlwubTypGoxb7al06FiNwfr3KDkytflKRGTyMKYgchighuFCfBuePd13cjf1l19TYU7u7a+VuCVWi7pmhDGUkMi24s23OroQb7D14XX17v46wLrqJQi2nrXzN/DWXcn/ycq8IZ7ZFgN/uYlbpfAKX8PCvImbDDO8+BgndAy4MPz8cWOWsnfGMVNePhvhazVcijLvx8Vu2Iuvg7CoJiSGjTe7YTms44/WpnFkHreyK8cwsw4wzls4BApu6UU2jIAsAMZh9zux/Rtni71dcNfF
bmk_enabled: 'False'
calico_cni_image: docker-prod-local.artifactory.mirantis.com/mirantis/projectcalico/calico/cni:latest
calico_enable_nat: 'True'
diff --git a/tcp_tests/templates/cookied-cicd-pike-dvr-sl/environment_context.yaml b/tcp_tests/templates/cookied-cicd-pike-dvr-sl/environment_context.yaml
index 1791477..5ed6d36 100644
--- a/tcp_tests/templates/cookied-cicd-pike-dvr-sl/environment_context.yaml
+++ b/tcp_tests/templates/cookied-cicd-pike-dvr-sl/environment_context.yaml
@@ -4,6 +4,8 @@
roles:
- infra_config
- linux_system_codename_xenial
+ classes:
+ - environment.cookied-cicd-pike-dvr-sl.override_ntp_virtual
interfaces:
ens3:
role: single_dhcp
diff --git a/tcp_tests/templates/shared-salt.yaml b/tcp_tests/templates/shared-salt.yaml
index aaaf9d4..88fef31 100644
--- a/tcp_tests/templates/shared-salt.yaml
+++ b/tcp_tests/templates/shared-salt.yaml
@@ -241,16 +241,16 @@
git checkout {{ SALT_MODELS_COMMIT }};
{%- endif %}
- {%- if SALT_MODELS_SYSTEM_COMMIT != '' %}
- pushd classes/system/;
- git checkout {{ SALT_MODELS_SYSTEM_COMMIT }};
- popd;
- {%- elif SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
+ {%- if SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
pushd classes/system/ && \
{%- for item in SALT_MODELS_SYSTEM_REF_CHANGE.split(" ") %}
git fetch {{ SALT_MODELS_SYSTEM_REPOSITORY }} {{ item }} && git cherry-pick FETCH_HEAD;
{%- endfor %}
popd;
+ {%- elif SALT_MODELS_SYSTEM_COMMIT != '' %}
+ pushd classes/system/;
+ git checkout {{ SALT_MODELS_SYSTEM_COMMIT }};
+ popd;
{%- elif SALT_MODELS_SYSTEM_TAG != '' %}
pushd classes/system/;
git fetch --all --tags --prune
@@ -345,18 +345,18 @@
{%- if CLUSTER_PRODUCT_MODELS != '' %}
echo "CLUSTER_PRODUCT_MODELS={{ CLUSTER_PRODUCT_MODELS }}"
{%- endif %}
- {%- if COOKIECUTTER_TEMPLATE_COMMIT != '' %}
- echo "COOKIECUTTER_TEMPLATE_COMMIT={{ COOKIECUTTER_TEMPLATE_COMMIT }}"
- {%- elif COOKIECUTTER_REF_CHANGE != '' %}
+ {%- if COOKIECUTTER_REF_CHANGE != '' %}
echo "COOKIECUTTER_REF_CHANGE={{ COOKIECUTTER_REF_CHANGE }}"
+ {%- elif COOKIECUTTER_TEMPLATE_COMMIT != '' %}
+ echo "COOKIECUTTER_TEMPLATE_COMMIT={{ COOKIECUTTER_TEMPLATE_COMMIT }}"
{%- elif COOKIECUTTER_TAG != '' %}
echo "COOKIECUTTER_TAG={{ COOKIECUTTER_TAG }}"
{%- endif %}
echo "SALT_MODELS_SYSTEM_REPOSITORY={{ SALT_MODELS_SYSTEM_REPOSITORY }}"
- {%- if SALT_MODELS_SYSTEM_COMMIT != '' %}
- echo "SALT_MODELS_SYSTEM_COMMIT={{ SALT_MODELS_SYSTEM_COMMIT }}"
- {%- elif SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
+ {%- if SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
echo "SALT_MODELS_SYSTEM_REF_CHANGE={{ SALT_MODELS_SYSTEM_REF_CHANGE }}"
+ {%- elif SALT_MODELS_SYSTEM_COMMIT != '' %}
+ echo "SALT_MODELS_SYSTEM_COMMIT={{ SALT_MODELS_SYSTEM_COMMIT }}"
{%- elif SALT_MODELS_SYSTEM_TAG != '' %}
echo "SALT_MODELS_SYSTEM_TAG={{ SALT_MODELS_SYSTEM_TAG }}"
{%- endif %}
@@ -373,14 +373,14 @@
pip install cookiecutter
export GIT_SSL_NO_VERIFY=true; git clone {{ COOKIECUTTER_TEMPLATES_REPOSITORY }} /root/cookiecutter-templates
- {%- if COOKIECUTTER_TEMPLATE_COMMIT != '' %}
- pushd /root/cookiecutter-templates
- git checkout {{ COOKIECUTTER_TEMPLATE_COMMIT }}
- popd
- {%- elif COOKIECUTTER_REF_CHANGE != '' %}
+ {%- if COOKIECUTTER_REF_CHANGE != '' %}
pushd /root/cookiecutter-templates
git fetch {{ COOKIECUTTER_TEMPLATES_REPOSITORY }} {{ COOKIECUTTER_REF_CHANGE }} && git checkout FETCH_HEAD
popd
+ {%- elif COOKIECUTTER_TEMPLATE_COMMIT != '' %}
+ pushd /root/cookiecutter-templates
+ git checkout {{ COOKIECUTTER_TEMPLATE_COMMIT }}
+ popd
{%- elif COOKIECUTTER_TAG != '' %}
pushd /root/cookiecutter-templates
git fetch --all --tags --prune
@@ -447,16 +447,16 @@
cmd: |
set -e;
set -x;
- {%- if SALT_MODELS_SYSTEM_COMMIT != '' %}
- pushd /srv/salt/reclass/classes/system/
- git checkout {{ SALT_MODELS_SYSTEM_COMMIT }};
- popd;
- {%- elif SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
+ {%- if SALT_MODELS_SYSTEM_REF_CHANGE != '' %}
pushd /srv/salt/reclass/classes/system/ && \
{%- for item in SALT_MODELS_SYSTEM_REF_CHANGE.split(" ") %}
git fetch {{ SALT_MODELS_SYSTEM_REPOSITORY }} {{ item }} && git cherry-pick FETCH_HEAD;
{%- endfor %}
popd;
+ {%- elif SALT_MODELS_SYSTEM_COMMIT != '' %}
+ pushd /srv/salt/reclass/classes/system/
+ git checkout {{ SALT_MODELS_SYSTEM_COMMIT }};
+ popd;
{%- elif SALT_MODELS_SYSTEM_TAG != '' %}
pushd /srv/salt/reclass/classes/system/
git fetch --all --tags --prune
diff --git a/tcp_tests/tests/system/test_3rdparty_suites.py b/tcp_tests/tests/system/test_3rdparty_suites.py
new file mode 100644
index 0000000..d545532
--- /dev/null
+++ b/tcp_tests/tests/system/test_3rdparty_suites.py
@@ -0,0 +1,93 @@
+# Copyright 2016 Mirantis, Inc.
+#
+# 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.
+
+import pytest
+
+from tcp_tests import logger
+from tcp_tests import settings
+
+LOG = logger.logger
+
+
+class Test3rdpartySuites(object):
+ """Test class for running 3rdparty test suites
+
+ Requires environment variables:
+ ENV_NAME
+ LAB_CONFIG_NAME
+ TESTS_CONFIGS
+ """
+
+ @pytest.mark.grab_versions
+ @pytest.mark.parametrize("_", [settings.ENV_NAME])
+ @pytest.mark.run_tempest
+ def test_run_tempest(self, tempest_actions, show_step, _):
+ """Runner for Juniper contrail-tests
+
+ Scenario:
+ 1. Run tempest
+ """
+ show_step(1)
+ tempest_actions.prepare_and_run_tempest()
+
+ @pytest.mark.grab_versions
+ @pytest.mark.parametrize("_", [settings.ENV_NAME])
+ @pytest.mark.run_stacklight
+ def test_run_stacklight(self, sl_actions, show_step, _):
+ """Runner for Stacklight tests
+
+ Scenario:
+ 1. Run SL test
+ """
+
+ # Run SL component tetsts
+ show_step(1)
+ sl_actions.setup_sl_functional_tests(
+ 'cfg01',
+ )
+ sl_actions.run_sl_functional_tests(
+ 'cfg01',
+ '/root/stacklight-pytest/stacklight_tests/',
+ 'tests/prometheus',
+ 'test_alerts.py',
+ junit_report_name='stacklight_report.xml')
+ # Download report
+ sl_actions.download_sl_test_report(
+ 'cfg01',
+ '/root/stacklight-pytest/stacklight_tests/'
+ 'stacklight_report.xml')
+
+ @pytest.mark.grab_versions
+ @pytest.mark.extract(container_system='docker', extract_from='conformance',
+ files_to_extract=['report'])
+ @pytest.mark.merge_xunit(path='/root/report',
+ output='/root/conformance_result.xml')
+ @pytest.mark.grab_k8s_results(name=['k8s_conformance.log',
+ 'conformance_result.xml'])
+ @pytest.mark.parametrize("_", [settings.ENV_NAME])
+ @pytest.mark.k8s_conformance
+ def test_run_k8s_conformance(self, show_step, config, k8s_actions,
+ k8s_logs, _):
+ """Test run of k8s conformance tests"""
+ k8s_actions.run_conformance()
+
+ @pytest.mark.grab_versions
+ @pytest.mark.grab_k8s_results(name=['virtlet_conformance.log',
+ 'report.xml'])
+ @pytest.mark.parametrize("_", [settings.ENV_NAME])
+ @pytest.mark.k8s_conformance_virtlet
+ def test_run_k8s_conformance_virtlet(self, show_step, config, k8s_actions,
+ k8s_logs, _):
+ """Test run of k8s virtlet conformance tests"""
+ k8s_actions.run_virtlet_conformance()
diff --git a/tcp_tests/tests/system/test_k8s_actions.py b/tcp_tests/tests/system/test_k8s_actions.py
index 6510a67..11cb56a 100644
--- a/tcp_tests/tests/system/test_k8s_actions.py
+++ b/tcp_tests/tests/system/test_k8s_actions.py
@@ -189,6 +189,7 @@
@pytest.mark.grap_versions
@pytest.mark.fail_snapshot
+ @pytest.mark.k8s_genie
def test_k8s_genie_flannel(self, show_step, config,
salt_deployed, k8s_deployed):
"""Test genie-cni+flannel cni setup