Execution of kvm4nfv cyclictest based on job type.
[kvmfornfv.git] / ci / test_kvmfornfv.sh
1 #!/bin/bash
2
3 ############################################################
4 ## This script  is an interface to trigger the
5 ## cyclicTestTrigger.sh for test type like patch verification,
6 ## daily testing.
7 ## Releng will trigger this script by passing test type like
8 ## verify/daily as an argument
9 ############################################################
10
11 test_type=$1
12
13 if [ ${test_type} == "verify" ];then
14    HOST_IP="10.2.117.23"
15    test_time=600000 # 10m
16 elif [ ${test_type} == "daily" ];then
17    HOST_IP="10.2.117.25"
18    test_time=7200000 #2h
19 elif [ ${test_type} == "merge" ];then
20    echo "Test is not enabled for ${test_type}"
21    exit 0
22 fi
23
24 source $WORKSPACE/ci/cyclicTestTrigger.sh $HOST_IP $test_time $test_type
25
26 #Update cyclictest-node-context.yaml with test_time and pod.yaml with IP
27 updateYaml
28
29 #Cleaning up the test environment before running cyclictest through yardstick.
30 env_clean
31
32 #Creating a docker image with yardstick installed and launching ubuntu docker to run yardstick cyclic testcase
33 runCyclicTest