Support {project}-{functionality}-{stream}.txt testplans 74/35774/4
authorVratko Polak <vrpolak@cisco.com>
Fri, 4 Mar 2016 11:31:18 +0000 (12:31 +0100)
committerVratko Polak <vrpolak@cisco.com>
Wed, 16 Mar 2016 11:59:38 +0000 (12:59 +0100)
The existing {project}-{functionality}.txt ones are used as a fallback.

Change-Id: I8d96171f223e54382e9737dc6758deb772065065
Signed-off-by: Vratko Polak <vrpolak@cisco.com>
jjb/integration/include-raw-integration-deploy-controller-run-test.sh
jjb/integration/include-raw-integration-start-cluster-run-test.sh
jjb/integration/integration-macros.yaml
jjb/integration/integration-templates.yaml
jjb/integration/integration-test-jobs.yaml

index fdf0f8a8d791c9585cc4f47c8bd51c6617339e85..1eb50f14df939996e7b05cc8524220c30130c751 100644 (file)
@@ -132,8 +132,14 @@ EOF
 scp ${WORKSPACE}/controller-script.sh ${ODL_SYSTEM_IP}:/tmp
 ssh ${ODL_SYSTEM_IP} 'bash /tmp/controller-script.sh'
 
+echo "Locating test plan to use..."
+testplan_filepath="${WORKSPACE}/test/csit/testplans/${STREAMTESTPLAN}"
+if [ ! -f "${testplan_filepath}" ]; then
+    testplan_filepath="${WORKSPACE}/test/csit/testplans/${TESTPLAN}"
+fi
+
 echo "Changing the testplan path..."
-cat ${WORKSPACE}/test/csit/testplans/${TESTPLAN} | sed "s:integration:${WORKSPACE}:" > testplan.txt
+cat "${testplan_filepath}" | sed "s:integration:${WORKSPACE}:" > testplan.txt
 cat testplan.txt
 
 SUITES=$( egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' testplan.txt | tr '\012' ' ' )
index 867a1bdebffbf1a0277f5c374842b93fab5d8cf5..014e3b16d280d021b705a0f9ec372c8429410b52 100644 (file)
@@ -75,12 +75,6 @@ fi
 echo "Cool down for ${COOLDOWN_PERIOD} seconds :)..."
 sleep ${COOLDOWN_PERIOD}
 
-echo "Changing the testplan path..."
-cat ${WORKSPACE}/test/csit/testplans/${TESTPLAN} | sed "s:integration:${WORKSPACE}:" > testplan.txt
-cat testplan.txt
-
-SUITES=`egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' testplan.txt | tr '\012' ' '`
-
 echo "Generating controller variables..."
 for i in `seq 1 ${NUM_ODL_SYSTEM}`
 do
@@ -95,6 +89,18 @@ do
     tools_variables=${tools_variables}" -v ${MININETIP}:${!MININETIP}"
 done
 
+echo "Locating test plan to use..."
+testplan_filepath="${WORKSPACE}/test/csit/testplans/${STREAMTESTPLAN}"
+if [ ! -f "${testplan_filepath}" ]; then
+    testplan_filepath="${WORKSPACE}/test/csit/testplans/${TESTPLAN}"
+fi
+
+echo "Changing the testplan path..."
+cat "${testplan_filepath}" | sed "s:integration:${WORKSPACE}:" > testplan.txt
+cat testplan.txt
+
+SUITES=`egrep -v '(^[[:space:]]*#|^[[:space:]]*$)' testplan.txt | tr '\012' ' '`
+
 echo "Starting Robot test suites ${SUITES} ..."
 pybot -N ${TESTPLAN} -c critical -e exclude -v BUNDLEFOLDER:${BUNDLEFOLDER} -v WORKSPACE:/tmp -v BUNDLE_URL:${ACTUALBUNDLEURL} \
 -v NEXUSURL_PREFIX:${NEXUSURL_PREFIX} -v JDKVERSION:${JDKVERSION} -v ODL_STREAM:${DISTROSTREAM} \
index 496db36580b67e2093279ef94d95365fca8f7e80..27878201fb0f729fb5547afc04a87275dda9d2a3 100644 (file)
             default: '{stream}'
             description: 'Distribution stream string, for suites to know which behavior to expect'
 
+- parameter:
+    name: integration-stream-test-plan
+    parameters:
+        - string:
+            name: STREAMTESTPLAN
+            default: '{stream-test-plan}'
+            description: 'Stream-specific test plan we will run'
+
 - parameter:
     name: integration-test-plan
     parameters:
         - string:
             name: TESTPLAN
             default: '{test-plan}'
-            description: 'Test plan we will run'
+            description: 'General test plan we will run unless stream-specific one is found'
 
 - parameter:
     name: integration-test-options
index 08329f7d3edea094ffc2616f6cc626d6f6c5d91c..b05bb55131128c7a781f82a2f321cfbfde94956b 100644 (file)
@@ -17,7 +17,8 @@
 # integration-controller-scope: only or all features ($CONTROLLERSCOPE)
 # integration-controller-features: features under test ($CONTROLLER FEATURES)
 # integration-test-options: robot options ($TESTOPTIONS)
-# integration-test-plan: robot test plan ($TESTPLAN)
+# integration-stream-test-plan: stream specific robot test plan ($STREAMTESTPLAN)
+# integration-test-plan: fallback robot test plan ($TESTPLAN)
 # integration-patch-refspec: test branch ($PATCHREFSPEC)
 
 
@@ -51,6 +52,8 @@
             controller-features: '{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-jdk-version:
             controller-features: '{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-patch-refspec:
             controller-features: '{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-patch-refspec:
             controller-features: 'odl-mdsal-clustering,{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-jdk-version:
             controller-features: 'odl-mdsal-clustering,{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-patch-refspec:
             controller-features: 'odl-mdsal-clustering,{install-features}'
         - integration-test-options:
             test-options: '{robot-options}'
+        - integration-stream-test-plan:
+            stream-test-plan: '{project}-{functionality}-{stream}.txt'
         - integration-test-plan:
             test-plan: '{project}-{functionality}.txt'
         - integration-patch-refspec:
index f596e3e31199da3ef4eda7a3ede93900f15bed45..50134b9650cb9ed5e7b25c3cfd54ebb285c0c3f7 100644 (file)
                 odl-netconf-connector-all
         - integration-test-options:
             test-options: '-e adsal -v TIMEOUT_BUG_4220:10s'
+        - integration-stream-test-plan:
+            stream-test-plan: 'test-libraries-beryllium.txt'
         - integration-test-plan:
             test-plan: 'test-libraries.txt'
         - integration-patch-refspec: