summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorxudan <xudan16@huawei.com>2017-10-17 05:27:10 -0400
committerLeo wang <grakiss.wanglei@huawei.com>2017-10-23 07:08:53 +0000
commita5c7a5358ab160f7518798dc977bf85fed32ddb9 (patch)
treea9896027d384ae1dbfd4d91c924c4ad62da4ccd5
parent26276a276dd37d2fbc7d26dc338613b928dbbfb3 (diff)
Use functest clean module to do the sdnvpn resources cleanup
1. If there throw an exception during the test of one sdnvpn test case, it will not do the clean. 2. Then there are many resources left, such as network, subnet, server... 3. This is a bug of sdnvpn see JIRA: SDNVPN-184 4. The patch for fixing this bug https://gerrit.opnfv.org/gerrit/#/c/44777/ 5. Currently, use functest module "functest openstack clean" to clean the SUT. JIRA: DOVETAIL-524 Change-Id: I629fc6fdc9e4c95960f6122358ff219a467d441b Signed-off-by: xudan <xudan16@huawei.com>
-rw-r--r--dovetail/testcase/sdnvpn.tc001.yml3
-rw-r--r--dovetail/testcase/sdnvpn.tc002.yml3
-rw-r--r--dovetail/testcase/sdnvpn.tc003.yml3
-rw-r--r--dovetail/testcase/sdnvpn.tc004.yml3
-rw-r--r--dovetail/testcase/sdnvpn.tc008.yml3
5 files changed, 15 insertions, 0 deletions
diff --git a/dovetail/testcase/sdnvpn.tc001.yml b/dovetail/testcase/sdnvpn.tc001.yml
index 786892be..b5d6ad0c 100644
--- a/dovetail/testcase/sdnvpn.tc001.yml
+++ b/dovetail/testcase/sdnvpn.tc001.yml
@@ -8,8 +8,11 @@ dovetail.sdnvpn.tc001:
pre_condition:
- "sed -i 's/testcase_1/sdnvpn.test.functest.testcase_1/' /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/testcase_1.py"
- "sed -i 's/run_sdnvpn_tests.py/run_sdnvpn_tests.py -r/' /usr/local/lib/python2.7/dist-packages/functest/ci/testcases.yaml"
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack snapshot-create"
pre_copy:
exist_src_file: sdnvpn_config_testcase1.yaml
dest_path: /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/config.yaml
+ post_condition:
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack clean"
report:
sub_testcase_list:
diff --git a/dovetail/testcase/sdnvpn.tc002.yml b/dovetail/testcase/sdnvpn.tc002.yml
index 900fb461..ce2fa44f 100644
--- a/dovetail/testcase/sdnvpn.tc002.yml
+++ b/dovetail/testcase/sdnvpn.tc002.yml
@@ -8,8 +8,11 @@ dovetail.sdnvpn.tc002:
pre_condition:
- "sed -i 's/testcase_2/sdnvpn.test.functest.testcase_2/' /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/testcase_2.py"
- "sed -i 's/run_sdnvpn_tests.py/run_sdnvpn_tests.py -r/' /usr/local/lib/python2.7/dist-packages/functest/ci/testcases.yaml"
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack snapshot-create"
pre_copy:
exist_src_file: sdnvpn_config_testcase2.yaml
dest_path: /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/config.yaml
+ post_condition:
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack clean"
report:
sub_testcase_list:
diff --git a/dovetail/testcase/sdnvpn.tc003.yml b/dovetail/testcase/sdnvpn.tc003.yml
index 8d28b57c..ad8c1dc1 100644
--- a/dovetail/testcase/sdnvpn.tc003.yml
+++ b/dovetail/testcase/sdnvpn.tc003.yml
@@ -8,8 +8,11 @@ dovetail.sdnvpn.tc003:
pre_condition:
- "sed -i 's/testcase_3/sdnvpn.test.functest.testcase_3/' /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/testcase_3.py"
- "sed -i 's/run_sdnvpn_tests.py/run_sdnvpn_tests.py -r/' /usr/local/lib/python2.7/dist-packages/functest/ci/testcases.yaml"
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack snapshot-create"
pre_copy:
exist_src_file: sdnvpn_config_testcase3.yaml
dest_path: /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/config.yaml
+ post_condition:
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack clean"
report:
sub_testcase_list:
diff --git a/dovetail/testcase/sdnvpn.tc004.yml b/dovetail/testcase/sdnvpn.tc004.yml
index 236c39bd..e00adfac 100644
--- a/dovetail/testcase/sdnvpn.tc004.yml
+++ b/dovetail/testcase/sdnvpn.tc004.yml
@@ -8,8 +8,11 @@ dovetail.sdnvpn.tc004:
pre_condition:
- "sed -i 's/testcase_4/sdnvpn.test.functest.testcase_4/' /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/testcase_4.py"
- "sed -i 's/run_sdnvpn_tests.py/run_sdnvpn_tests.py -r/' /usr/local/lib/python2.7/dist-packages/functest/ci/testcases.yaml"
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack snapshot-create"
pre_copy:
exist_src_file: sdnvpn_config_testcase4.yaml
dest_path: /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/config.yaml
+ post_condition:
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack clean"
report:
sub_testcase_list:
diff --git a/dovetail/testcase/sdnvpn.tc008.yml b/dovetail/testcase/sdnvpn.tc008.yml
index a4d82316..e643ec20 100644
--- a/dovetail/testcase/sdnvpn.tc008.yml
+++ b/dovetail/testcase/sdnvpn.tc008.yml
@@ -8,8 +8,11 @@ dovetail.sdnvpn.tc008:
pre_condition:
- "sed -i 's/testcase_8/sdnvpn.test.functest.testcase_8/' /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/testcase_8.py"
- "sed -i 's/run_sdnvpn_tests.py/run_sdnvpn_tests.py -r/' /usr/local/lib/python2.7/dist-packages/functest/ci/testcases.yaml"
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack snapshot-create"
pre_copy:
exist_src_file: sdnvpn_config_testcase8.yaml
dest_path: /usr/local/lib/python2.7/dist-packages/sdnvpn/test/functest/config.yaml
+ post_condition:
+ - "source /home/opnfv/functest/conf/openstack.creds && functest openstack clean"
report:
sub_testcase_list: