Skip to content

Commit

Permalink
Running tests on 6.0 setup
Browse files Browse the repository at this point in the history
  • Loading branch information
ashahi1 committed Feb 9, 2018
1 parent 298b030 commit 9966107
Showing 1 changed file with 44 additions and 41 deletions.
85 changes: 44 additions & 41 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,24 @@ node("vdvs-slave-two") {

def app

def ERROR = 'false'

dir('vsphere-storage-for-docker') {
sh "echo Deleting \\${JOB_NAME} "
deleteDir()
}

stage('Checkout code') {
/* Let's make sure we have the repository cloned to our workspace.. */
checkout scm
/* Let's make sure we have the repository cloned to our workspace.*/
checkout scm
/* sh "cat Jenkinsfile" */
}

stage('Build binaries') {
/* This builds binaries */

sh "echo Building the VDVS binaries"
sh "export PKG_VERSION=$BUILD_NUMBER"
sh "echo ESX=$ESX; echo VM1=$VM1; echo VM2=$VM2; echo VM3=$VM3; echo PKG_VERSION"
sh "make build-all"
sh "echo Building the VDVS binaries"
sh "export PKG_VERSION=$BUILD_NUMBER"
sh "echo ESX=$ESX; echo VM1=$VM1; echo VM2=$VM2; echo VM3=$VM3; echo PKG_VERSION"*/
sh "make build-all"
}

stage('Deploy - 6.5 setup') {
Expand All @@ -30,30 +28,29 @@ node("vdvs-slave-two") {
sh "echo deploying binaries"
sh "echo ESX = $ESX; echo VM1=$VM1; echo VM2=$VM2; echo VM3=$VM3;"
sh "make deploy-all"
sh "echo finished deploying the binaries"

sh "echo finished deploying the binaries"
}

stage('Executing End-to-End Tests') {
/* This runs the e2e test */
stage('vDVS Tests') {
/* This runs the vDVS tests */

sh "echo starting e2e tests"
sh "make test-e2e"
sh "make test-esx"
sh "make test-vm"
sh "echo starting e2e tests"
sh "make test-e2e"
sh "make test-esx"
sh "make test-vm"
}


stage('vFile Tests') {
/* This runs the tests for vFile Plugin */
sh "echo Build, deploy and test vFile plugin"
sh "make build-vfile-all ; make deploy-vfile-plugin; make test-e2e-vfile"
/* This runs the vFile tests; */

sh "echo Build, deploy and test vFile plugin"
sh "make build-vfile-all ; make deploy-vfile-plugin; make test-e2e-vfile"
}

stage('Build Windows plugin') {
/* This builds the actual windows image; */

sh "echo building binaries for windows"
sh "make build-windows-plugin"
sh "echo Finished building binaries for windows"
Expand All @@ -63,43 +60,49 @@ node("vdvs-slave-two") {
/* This deploys the windows plugin image; */

sh "echo deploying binaries for windows"
sh "ls"
sh "echo Windows-VM = $WIN_VM1"
sh "make deploy-windows-plugin"
sh "echo Finished building binaries for windows"

}

stage('Executing Windows Plugin Tests') {
/* This runs the tests for Windows Plugin */
sh "echo Starting test for Windows"
sh "make test-e2e-windows"

sh "echo Starting test for Windows"
sh "make test-e2e-windows"
}

stage('Deploy - 6.0 setup') {
/* This deploys the actual code */
/* This deploys the actual code. */

sh " ESX=; VM1=; VM2=; VM3="
sh "echo ESX is ${env.ESX60} , VM1 is ${env.VM160}, VM2 is ${env.VM260} and VM3 is ${env.VM360}"

sh "export ESX=$ESX60; export VM1=$VM160; export VM2=$VM260; export VM3=$VM360"
sh "export MANAGER1=$MANAGER160; export WORKER1=$WORKER160; export WORKER2=$WORKER260"
sh "echo deploying binaries to 6.0 setup"
sh "echo ESX = $ESX; echo VM1=$VM1; echo VM2=$VM2; echo VM3=$VM3"
sh "make deploy-all"
sh "echo finished deploying the binaries"
withEnv(["ESX=${env.ESX60}", "VM1=${env.VM160}", "VM2=${env.VM260}", "VM3=${env.VM360}", "MANAGER1=${env.MANAGER160}", "WORKER1=${env.WORKER160}", "WORKER2=${env.WORKER260}"]){
sh "printenv"
sh "echo deploying binaries to 6.0 setup"
sh "make deploy-all"
sh "echo finished deploying the binaries"
}
}

stage('Executing VDVS tests on 6.0 ESX') {
/* This runs the e2e test */

sh "echo starting e2e tests"
sh "make test-e2e"
sh "make test-esx"
sh "make test-vm"

withEnv(["ESX=${env.ESX60}", "VM1=${env.VM160}", "VM2=${env.VM260}", "VM3=${env.VM360}", "MANAGER1=${env.MANAGER160}", "WORKER1=${env.WORKER160}", "WORKER2=${env.WORKER260}"]){
sh "echo starting e2e tests"
sh "make test-e2e"
sh "make test-esx"
sh "make test-vm"
}
}

stage('Executing vFile tests on 6.0 ESX') {
/* This runs the tests for vFile Plugin. */
sh "echo Build, deploy and test vFile plugin"
sh "make build-vfile-all ; make deploy-vfile-plugin; make test-e2e-vfile || \\${ERROR}=true"
/* This runs the tests for vFile Plugin. */

withEnv(["ESX=${env.ESX60}", "VM1=${env.VM160}", "VM2=${env.VM260}", "VM3=${env.VM360}", "MANAGER1=${env.MANAGER160}", "WORKER1=${env.WORKER160}", "WORKER2=${env.WORKER260}"]){
sh "echo Build, deploy and test vFile plugin"
sh "make build-vfile-all ; make deploy-vfile-plugin; make test-e2e-vfile"
}
}
}

0 comments on commit 9966107

Please sign in to comment.