Modify tempest.conf to enable Tempest failed test cases to pass on Compass 43/39743/1
authorxudan <xudan16@huawei.com>
Mon, 21 Aug 2017 10:03:00 +0000 (06:03 -0400)
committerxudan <xudan16@huawei.com>
Mon, 21 Aug 2017 10:12:19 +0000 (06:12 -0400)
JIRA: DOVETAIL-486

For compass:
1. There is a defcore test case always failed due to wrong value of
   volume_device_name=vdc.
   Use tempest_conf.yaml to change the wrong value into 'vdb' for Compass.
2. There are also some tempest test cases skipped or failed due to wrong values
   in tempest.conf file.

Change-Id: Ibe274790b14d9223b5c0ee903879f8b67521948d
Signed-off-by: xudan <xudan16@huawei.com>
jjb/dovetail/dovetail-run.sh

index 7bbecc1..d05b309 100755 (executable)
@@ -160,6 +160,37 @@ if [ $(docker ps | grep "opnfv/dovetail:${DOCKER_TAG}" | wc -l) == 0 ]; then
     exit 1
 fi
 
+# Modify tempest_conf.yaml file
+tempest_conf_file=${DOVETAIL_CONFIG}/tempest_conf.yaml
+if [ ${INSTALLER_TYPE} == 'compass' ]; then
+    volume_device='vdb'
+else
+    volume_device='vdc'
+fi
+
+cat << EOF >$tempest_conf_file
+
+compute:
+    min_compute_nodes: 2
+    volume_device_name: ${volume_device}
+    min_microversion: 2.0
+    max_microversion: latest
+
+compute-feature-enabled:
+    live_migration: True
+    block_migration_for_live_migration: True
+    block_migrate_cinder_iscsi: True
+    attach_encrypted_volume: True
+
+EOF
+
+echo "${tempest_conf_file}..."
+cat ${tempest_conf_file}
+
+cp_tempest_cmd="docker cp ${DOVETAIL_CONFIG}/tempest_conf.yaml $container_id:/home/opnfv/dovetail/dovetail/userconfig"
+echo "exec command: ${cp_tempest_cmd}"
+$cp_tempest_cmd
+
 list_cmd="dovetail list ${TESTSUITE}"
 run_cmd="dovetail run --testsuite ${TESTSUITE} -d"
 echo "Container exec command: ${list_cmd}"