modifying cord-test jjb jobs

Change-Id: I12e722be72d7b56d4ca1add0a2466b918d8a908e
diff --git a/jjb/cord-test/att-workflow.yaml b/jjb/cord-test/att-workflow.yaml
index a90abe1..eaf9f3a 100644
--- a/jjb/cord-test/att-workflow.yaml
+++ b/jjb/cord-test/att-workflow.yaml
@@ -14,9 +14,10 @@
          config-pod: 'onlab-pod1'
          profile: 'att-workflow'
          branch: 'master'
-         scenario: ''
          Jenkinsfile: 'Jenkinsfile-attworkflow-build'
          oltDebVersion: 'openolt-master.deb'
+         configurePod: true
+         oltsPresent: true
 
     # flex pod1 with olt/onu
       - 'build_pod_manual':
@@ -24,6 +25,7 @@
          config-pod: 'flex-pod1-olt'
          profile: 'att-workflow'
          branch: 'master'
-         scenario: ''
          Jenkinsfile: 'Jenkinsfile-attworkflow-build'
          oltDebVersion: 'openolt-master.deb'
+         configurePod: true
+         oltsPresent: true
diff --git a/jjb/cord-test/nightly-build-pipeline.yaml b/jjb/cord-test/nightly-build-pipeline.yaml
index 279ae96..3ecba2e 100644
--- a/jjb/cord-test/nightly-build-pipeline.yaml
+++ b/jjb/cord-test/nightly-build-pipeline.yaml
@@ -15,7 +15,7 @@
 
 
 - job-template:
-    name: 'build_{profile}_{config-pod}_{scenario}_{branch}'
+    name: 'build_{profile}_{config-pod}_{branch}'
     id: build_pod_manual
     description: |
                   <!-- Managed by Jenkins Job Builder -->
@@ -71,11 +71,21 @@
          name: branch
          default: '{branch}'
 
+      - string:
+         name: profile
+         default: '{profile}'
+         description: 'Profile in which this job installs'
+
       - bool:
           name: configurePod
           default: true
           description: "Configure POD via TOSCA post build"
 
+      - bool:
+          name: oltsPresent
+          default: false
+          description: "Set to true if OLTs present in this POD or if you do NOT want OLT software to be re-installed"
+
       - string:
          name: notificationEmail
          default: 'kailash@opennetworking.org, you@opennetworking.org, suchitra@opennetworking.org'
@@ -92,7 +102,7 @@
              - '{branch}'
 
 - job-template:
-    name: 'build_{profile}_{config-pod}_{scenario}_{branch}'
+    name: 'build_{profile}_{config-pod}_{branch}'
     id: build_pod_timer
     description: |
                   <!-- Managed by Jenkins Job Builder -->
@@ -149,15 +159,25 @@
          default: '{branch}'
 
       - string:
-         name: notificationEmail
-         default: 'kailash@opennetworking.org, you@opennetworking.org, suchitra@opennetworking.org'
-         description: ''
+         name: profile
+         default: '{profile}'
+         description: 'Profile in which this job installs'
 
       - bool:
           name: configurePod
           default: true
           description: "Configure POD via TOSCA post build"
 
+      - bool:
+          name: oltsPresent
+          default: false
+          description: "Set to true if OLTs present in this POD or if you do NOT want OLT software to be re-installed"
+
+      - string:
+         name: notificationEmail
+         default: 'kailash@opennetworking.org, you@opennetworking.org, suchitra@opennetworking.org'
+         description: ''
+
     concurrent: true
 
     pipeline-scm:
@@ -172,3 +192,75 @@
        - timed: |
                  TZ=America/Los_Angeles
                  H {time} {day} * *
+
+- job-template:
+    name: 'build_{profile}_{config-pod}_{branch}_test'
+    id: build_pod_test
+    description: |
+                  <!-- Managed by Jenkins Job Builder -->
+                  Post Tests on {config-pod} triggered by build_{config-pod}_{branch} <br /><br />
+                  Created from job-template {id} from ci-management/jjb/cord-test/cord-test-pipeline.yaml <br />
+                  Created by Kailash Khalasi - kailash@opennetworking.org <br />
+                  Copyright (c) 2017 Open Networking Foundation (ONF)
+
+    <<: *test-pipe-job-boiler-plate
+
+    parameters:
+      - string:
+         name: TestNodeName
+         default: '{testvm}'
+         description: 'Jenkins node name of TestVM Node'
+
+      - string:
+         name: cordRepoUrl
+         default: '{gerrit-server-url}'
+         description: 'The URL of the CORD Project repository'
+
+      - string:
+         name: configBaseDir
+         default: 'pod-configs'
+         description: 'The directory inside the POD configs repository'
+
+      - string:
+         name: configDeploymentDir
+         default: 'deployment-configs'
+         description: 'The deployment configs folder'
+
+      - string:
+         name: configKubernetesDir
+         default: 'kubernetes-configs'
+         description: 'The kubernetes config folder'
+
+      - string:
+         name: configToscaDir
+         default: 'tosca-configs'
+         description: 'The tosca config folder'
+
+      - string:
+         name: configFileName
+         default: '{config-pod}'
+         description: 'The config file'
+
+      - string:
+         name: branch
+         default: '{branch}'
+
+      - string:
+         name: notificationEmail
+         default: 'kailash@opennetworking.org, you@opennetworking.org, suchitra@opennetworking.org'
+         description: ''
+
+    concurrent: true
+
+    pipeline-scm:
+      script-path: '{Jenkinsfile}'
+      scm:
+        - git:
+           url: '{gerrit-server-url}/cord-tester'
+           branches:
+             - '{branch}'
+
+    triggers:
+      - reverse:
+          jobs: 'build_{profile}_{config-pod}_{branch}'
+          result: 'success'
diff --git a/jjb/cord-test/rcord-lite.yaml b/jjb/cord-test/rcord-lite.yaml
index 92d0dee..0748e75 100644
--- a/jjb/cord-test/rcord-lite.yaml
+++ b/jjb/cord-test/rcord-lite.yaml
@@ -10,26 +10,26 @@
 
     jobs:
       # flex onf pod 1 kubernetes build jobs (rcord lite)
-      - 'build_pod_timer':
+      - 'build_pod_manual':
          testvm: 'qa-testvm-pod'
          config-pod: 'flex-onf-pod1'
-         profile: 'rcord'
-         scenario: 'topdown'
+         profile: 'rcord-topdown'
          branch: 'master'
          Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-build'
          oltDebVersion: 'openolt-1.4.deb'
-         time: '20'
-         day: '0-31/1'
+         configurePod: true
+         oltsPresent: false
 
      # flex pod1 with olt/onu  kubernetes build jobs (rcord lite)
       - 'build_pod_timer':
          testvm: 'qa-testvm-pod'
          config-pod: 'flex-pod1-olt'
-         profile: 'rcord'
+         profile: 'rcord-zerotouch'
          branch: 'cord-6.0'
-         scenario: 'zerotouch'
          Jenkinsfile: 'Jenkinsfile-rcordlite-zerotouch-build'
          oltDebVersion: 'openolt-1.4.deb'
+         configurePod: true
+         oltsPresent: true
          time: '0'
          day: '1-31/2'
 
@@ -37,11 +37,12 @@
       - 'build_pod_timer':
          testvm: 'qa-testvm-pod'
          config-pod: 'flex-pod1-olt'
-         profile: 'rcord'
+         profile: 'rcord-topdown'
          branch: 'cord-6.0'
-         scenario: 'topdown'
          Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-build'
          oltDebVersion: 'openolt-1.4.deb'
+         configurePod: true
+         oltsPresent: true
          time: '0'
          day: '2-30/2'
 
@@ -49,11 +50,12 @@
       - 'build_pod_timer':
          testvm: 'qa-testvm-pod'
          config-pod: 'flex-pod1-olt'
-         profile: 'rcord'
+         profile: 'rcord-zerotouch'
          branch: 'master'
-         scenario: 'zerotouch'
          Jenkinsfile: 'Jenkinsfile-rcordlite-zerotouch-build'
          oltDebVersion: 'openolt-master'
+         configurePod: true
+         oltsPresent: true
          time: '1'
          day: '1-31/2'
 
@@ -61,11 +63,12 @@
       - 'build_pod_timer':
          testvm: 'qa-testvm-pod'
          config-pod: 'flex-pod1-olt'
-         profile: 'rcord'
+         profile: 'rcord-topdown'
          branch: 'master'
-         scenario: 'topdown'
          Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-build'
-         oltDebVersion: 'openolt-master'
+         oltDebVersion: 'openolt-master.deb'
+         configurePod: true
+         oltsPresent: true
          time: '1'
          day: '2-30/2'
 
@@ -73,23 +76,30 @@
       - 'build_pod_timer':
          testvm: 'qct-pod1'
          config-pod: 'qct-pod1'
-         profile: 'rcord'
+         profile: 'rcord-topdown'
          branch: 'master'
-         scenario: 'topdown'
          Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-build'
          oltDebVersion: 'openolt-1.4.deb'
+         configurePod: true
+         oltsPresent: false
          time: '0'
          day: '*'
 
+     # qct pod1 test jobs (rcord lite topdown)
+      - 'build_pod_test':
+         testvm: 'qct-pod1'
+         config-pod: 'qct-pod1'
+         profile: 'rcord-topdown'
+         branch: 'master'
+         Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-test'
+
      # flex ocp pod 2 kubernetes build jobs (rcord lite)
-      - 'build_pod_timer':
+      - 'build_pod_manual':
          testvm: 'flex-pod2'
          config-pod: 'flex-ocp-pod2'
-         profile: 'rcord'
-         scenario: 'topdown'
+         profile: 'rcord-topdown'
          branch: 'master'
          Jenkinsfile: 'Jenkinsfile-rcordlite-topdown-build'
          oltDebVersion: 'openolt-1.4.deb'
-         time: '30'
-         day: '0-31/1'
-
+         configurePod: true
+         oltsPresent: false