Skip to content

Instantly share code, notes, and snippets.

@koko-rauch
Last active May 1, 2017 09:48
Show Gist options
  • Save koko-rauch/0c0764c777e9e00607d64535998fb478 to your computer and use it in GitHub Desktop.
Save koko-rauch/0c0764c777e9e00607d64535998fb478 to your computer and use it in GitHub Desktop.
def runTestScript() {
String[] testsToRun = prepareTests()
def testScript = load "jenkins/test.groovy"
testScript.run(testsToRun)
}
def prepareTests(){
def myMap = [ 'test1' : params.runTest1, 'test2' : params.runTest2 ]
def testsToRun = []
myMap.each{ k, v -> if (v) testsToRun.add(k) }
return testsToRun
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment