summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCédric Ollivier <cedric.ollivier@orange.com>2018-06-21 18:11:09 +0200
committerCédric Ollivier <cedric.ollivier@orange.com>2018-06-21 21:08:01 +0200
commit518ad1e201389ecef17c0770a94793315d0d0fd7 (patch)
treef6f42721834b395c4427e6dd15c995d431d7cefb
parentc510c3f912fe095af08705eb694bb1f0a226f38c (diff)
Add the Barbican test suite
It eases verifying the functionality of a barbican installation. Change-Id: Iac2144ae6ba4d61b2b37bb5c7a0359edb3f222a6 Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
-rw-r--r--docker/smoke/Dockerfile6
-rw-r--r--docker/smoke/testcases.yaml15
-rw-r--r--functest/ci/testcases.yaml15
-rw-r--r--functest/opnfv_tests/openstack/tempest/tempest.py18
4 files changed, 52 insertions, 2 deletions
diff --git a/docker/smoke/Dockerfile b/docker/smoke/Dockerfile
index e8a6b5d55..4c9247c65 100644
--- a/docker/smoke/Dockerfile
+++ b/docker/smoke/Dockerfile
@@ -20,13 +20,15 @@ RUN apk --no-cache add --virtual .build-deps --update \
update-requirements -s --source /src/openstack-requirements /src/patrole/ && \
git clone --depth 1 https://github.com/openstack/neutron-tempest-plugin.git /src/neutron-tempest-plugin && \
update-requirements -s --source /src/openstack-requirements /src/neutron-tempest-plugin && \
+ git clone --depth 1 https://github.com/openstack/barbican-tempest-plugin.git /src/barbican-tempest-plugin && \
+ update-requirements -s --source /src/openstack-requirements /src/barbican-tempest-plugin/ && \
pip install --no-cache-dir --src /src -cupper-constraints.txt -cupper-constraints.opnfv.txt \
- /src/patrole /src/neutron-tempest-plugin -rthirdparty-requirements.txt && \
+ /src/patrole /src/barbican-tempest-plugin /src/neutron-tempest-plugin -rthirdparty-requirements.txt && \
git clone https://git.opendaylight.org/gerrit/p/integration/test.git /src/odl_test && \
(cd /src/odl_test && git checkout $ODL_TAG) && \
virtualenv --system-site-packages /src/tempest/.venv && \
rm -r upper-constraints.txt upper-constraints.opnfv.txt thirdparty-requirements.txt /src/odl_test/.git \
- /src/patrole /src/neutron-tempest-plugin && \
+ /src/patrole /src/barbican-tempest-plugin /src/neutron-tempest-plugin && \
mkdir -p /home/opnfv/functest/data/refstack && \
wget "https://refstack.openstack.org/api/v1/guidelines/${REFSTACK_TARGET}/tests?target=compute&type=required&alias=true&flag=false" \
-O /home/opnfv/functest/data/refstack/defcore.txt && \
diff --git a/docker/smoke/testcases.yaml b/docker/smoke/testcases.yaml
index d5fe5fa82..ca2126173 100644
--- a/docker/smoke/testcases.yaml
+++ b/docker/smoke/testcases.yaml
@@ -201,3 +201,18 @@ tiers:
run:
module: 'functest.opnfv_tests.openstack.tempest.tempest'
class: 'TempestNeutronTrunk'
+
+ -
+ case_name: barbican
+ project_name: functest
+ criteria: 100
+ blocking: false
+ description: >-
+ It leverages on the tempest plugin containing tests used to
+ verify the functionality of a barbican installation
+ dependencies:
+ installer: '^((?!fuel|apex|compass|daisy).)*$'
+ scenario: ''
+ run:
+ module: 'functest.opnfv_tests.openstack.tempest.tempest'
+ class: 'TempestBarbican'
diff --git a/functest/ci/testcases.yaml b/functest/ci/testcases.yaml
index caf8ca3da..53641af47 100644
--- a/functest/ci/testcases.yaml
+++ b/functest/ci/testcases.yaml
@@ -329,6 +329,21 @@ tiers:
module: 'functest.opnfv_tests.openstack.tempest.tempest'
class: 'TempestNeutronTrunk'
+ -
+ case_name: barbican
+ project_name: functest
+ criteria: 100
+ blocking: false
+ description: >-
+ It leverages on the tempest plugin containing tests used to
+ verify the functionality of a barbican installation
+ dependencies:
+ installer: '^((?!fuel|apex|compass|daisy).)*$'
+ scenario: ''
+ run:
+ module: 'functest.opnfv_tests.openstack.tempest.tempest'
+ class: 'TempestBarbican'
+
-
name: features
order: 2
diff --git a/functest/opnfv_tests/openstack/tempest/tempest.py b/functest/opnfv_tests/openstack/tempest/tempest.py
index d51337a1e..e6dc77fcb 100644
--- a/functest/opnfv_tests/openstack/tempest/tempest.py
+++ b/functest/opnfv_tests/openstack/tempest/tempest.py
@@ -321,6 +321,24 @@ class TempestNeutronTrunk(TempestCommon):
rconfig.write(config_file)
+class TempestBarbican(TempestCommon):
+ """Tempest Barbican testcase implementation."""
+ def __init__(self, **kwargs):
+ if "case_name" not in kwargs:
+ kwargs["case_name"] = 'barbican'
+ TempestCommon.__init__(self, **kwargs)
+ self.mode = "'barbican_tempest_plugin.tests.(api|scenario)'"
+ self.res_dir = os.path.join(
+ getattr(config.CONF, 'dir_results'), 'barbican')
+ self.raw_list = os.path.join(self.res_dir, 'test_raw_list.txt')
+ self.list = os.path.join(self.res_dir, 'test_list.txt')
+
+ def generate_test_list(self):
+ self.backup_tempest_config(self.conf_file, '/etc')
+ super(TempestBarbican, self).generate_test_list()
+ os.remove('/etc/tempest.conf')
+
+
class TempestSmokeParallel(TempestCommon):
"""Tempest smoke parallel testcase implementation."""
def __init__(self, **kwargs):