Update Jenkinsfile

Fixing error with test app builds in case when PR is done from a fork and the commit hash is not visible in test app build
pull/2752/head
Mika Karjalainen 2016-09-20 16:05:59 +03:00 committed by GitHub
parent e4a40cd6a7
commit 7e6882c284
1 changed files with 5 additions and 2 deletions

7
Jenkinsfile vendored
View File

@ -14,6 +14,9 @@ def toolchains = [
GCC_ARM: "arm-none-eabi-gcc"
]
// mbed.getCurrentBranch returns either local branch name or reference to pull request
def currentBranch = mbed.getCurrentBranch()
// Create a map of predefined build steps
def parallelSteps = mbed.createParalleSteps("mbed-os", targets, toolchains)
@ -25,5 +28,5 @@ def testApps = [
"mbed-client-testapp"
]
// buildTestApps accepts array of test application names and a mbed-os commit hash as parameters
mbed.buildTestApps(testApps, "${env.GIT_REVISION}")
// buildTestApps accepts array of test application names and a mbed-os branch or PR reference as parameters
mbed.buildTestApps(testApps, "${currentBranch}")