Skip to content

Commit 0577a7d

Browse files
author
Chris Park
committed
Move names and paths into variables
1 parent d57f777 commit 0577a7d

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

Jenkinsfile.examples

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
node {
22
def SOURCEDIR = pwd()
33
def TEST_CONTAINER = 'examples/python-test'
4+
def DOCKERFILE_DIR = './examples/docker'
45
try {
56
stage("Clean up") {
67
step([$class: 'WsCleanup'])
@@ -9,11 +10,11 @@ node {
910
checkout scm
1011
}
1112
stage("Build Dockerfile") {
12-
dir ('./examples/docker') {
13+
dir ("${DOCKERFILE_DIR}") {
1314
docker.build("${TEST_CONTAINER}")
1415
}
1516
}
16-
stage("Run Tests") {
17+
stage("Run Examples") {
1718
withEnv(["API_KEY=${env.ROSETTE_API_KEY}", "ALT_URL=${env.BINDING_TEST_URL}"]) {
1819
sh "docker run --rm -e API_KEY=${API_KEY} -e ALT_URL=${ALT_URL} -v ${SOURCEDIR}:/source ${TEST_CONTAINER}"
1920
}

0 commit comments

Comments
 (0)