@@ -12,6 +12,7 @@ properties([
1212 ])
1313])
1414
15+ def image = ' stanorg/ci:v1'
1516def runRemainingStages = false
1617def CLANG_CXX = ' clang++-7'
1718def GCC = ' g++'
@@ -33,16 +34,14 @@ def runTests(String local, String args) {
3334}
3435
3536catchError {
36- buildImage(context : ' ci' )
37-
3837 withEnv([
3938 ' GCC=g++' ,
4039 ' GIT_AUTHOR_NAME=Stan Jenkins' ,
4140 ' GIT_AUTHOR_EMAIL=mc.stanislaw@gmail.com' ,
4241 ' GIT_COMMITTER_NAME=Stan Jenkins' ,
4342 ' GIT_COMMITTER_EMAIL=mc.stanislaw@gmail.com'
4443 ]) {
45- runPod(cpus : 2 ) {
44+ runPod(image : image, cpus : 2 ) {
4645 stage(' Verify changes' ) {
4746 runRemainingStages = params. run_all || filesChanged(
4847 ' stan' , ' make' , ' lib' , ' test' , ' runTests.py' , ' runChecks.py' , ' makefile' , ' Jenkinsfile' , ' .clang-format' )
@@ -101,15 +100,15 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
101100 if (runRemainingStages) {
102101 stage(' Quick tests' ) {
103102 parallel headers : {
104- runPod([:] ) {
103+ runPod(image : image ) {
105104 stage(' Headers check' ) {
106105 writeFile(file : ' make/local' , text : " CXX=$CLANG_CXX -Werror" )
107106 sh ' make -j$PARALLEL test-headers'
108107 }
109108 }
110109 }, unit : {
111110 if (env. CHANGE_TARGET ) {
112- runPod([:] ) {
111+ runPod(image : image ) {
113112 stage(' Run changed unit tests' ) {
114113 writeFile(file : ' make/local' , text : " O=3\n CXXFLAGS+=-march=native -mtune=native" )
115114 sh ' ./runTests.py -j$PARALLEL --changed --debug'
@@ -122,7 +121,7 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
122121 stage(' Full Unit Tests' ) {
123122 parallel failFast : true ,
124123 revfwd : {
125- runPod([:] ) {
124+ runPod(image : image ) {
126125 stage(' Rev/Fwd Unit Tests' ) {
127126 def local = ' CXXFLAGS+= -fsanitize=address\n '
128127 if (noOptimize)
@@ -133,7 +132,7 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
133132 }
134133 },
135134 mix : {
136- runPod(memory : ' 128Gi' ) {
135+ runPod(image : image, memory : ' 128Gi' ) {
137136 stage(' Mix Unit Tests' ) {
138137 def local = ' CXXFLAGS+= -fsanitize=address\n '
139138 if (noOptimize)
@@ -143,7 +142,7 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
143142 }
144143 },
145144 prim : {
146- runPod([:] ) {
145+ runPod(image : image ) {
147146 stage(' Prim Unit Tests' ) {
148147 def local = ' CXXFLAGS+= -fsanitize=address\n '
149148 if (noOptimize)
@@ -156,7 +155,7 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
156155 }
157156 },
158157 laplace : {
159- runPod(memory : ' 32Gi' ) {
158+ runPod(image : image, memory : ' 32Gi' ) {
160159 stage(' Laplace Unit Tests' ) {
161160 def local = ' CXXFLAGS+= -march=native -mtune=native\n O=3\n '
162161 if (! noOptimize)
@@ -166,7 +165,7 @@ up the autoformatter locally. (Check console output at ${env.BUILD_URL})
166165 }
167166 },
168167 gpu : {
169- runPod(memory : ' 32Gi' , gpus : 1 ) {
168+ runPod(image : image, memory : ' 32Gi' , gpus : 1 ) {
170169 stage(' OpenCL GPU tests' ) {
171170 def local = """ CXX=$CLANG_CXX -Werror
172171STAN_OPENCL=true
@@ -185,7 +184,7 @@ OPENCL_DEVICE_ID=0
185184 stage(' Always-run tests' ) {
186185 parallel failFast : true ,
187186 mpi : {
188- runPod([:] ) {
187+ runPod(image : image ) {
189188 stage(' Laplace Unit Tests' ) {
190189 def local = " CXX=$MPICXX \n CXX_TYPE=gcc\n STAN_MPI=true\n "
191190 runTests(local, " test/unit/math/prim/functor" )
@@ -194,7 +193,7 @@ OPENCL_DEVICE_ID=0
194193 }
195194 },
196195 expr : {
197- runPod(memory : ' 64Gi' ) {
196+ runPod(image : image, memory : ' 64Gi' ) {
198197 stage(' Expressions test' ) {
199198 def local = " CXX=$CLANG_CXX -Werror\n O=0\n "
200199 writeFile(file : ' make/local' , text : local)
@@ -213,7 +212,7 @@ OPENCL_DEVICE_ID=0
213212 }
214213 },
215214 thread : {
216- runPod([:] ) {
215+ runPod(image : image ) {
217216 stage(' Threading tests' ) {
218217 def local = " CXX=$CLANG_CXX -Werror\n STAN_THREADS=true\n "
219218 if (mainBranch) {
@@ -230,7 +229,7 @@ OPENCL_DEVICE_ID=0
230229
231230 def cores_per_test = 6
232231 def parallel_tests = 10
233- runPod(cpus : cores_per_test* parallel_tests) {
232+ runPod(image : image, cpus : cores_per_test* parallel_tests) {
234233 stage (' Distribution tests' ) {
235234 def local = " CXX=$CLANG_CXX \n O=0\n N_TESTS=100\n "
236235 if (params. withRowVector || mainBranch) {
@@ -262,7 +261,7 @@ OPENCL_DEVICE_ID=0
262261 }
263262
264263 if (env. BRANCH_NAME == ' develop' ) {
265- runPod(cpus : 2 ) {
264+ runPod(image : image, cpus : 2 ) {
266265 stage(' Upload doxygen' ) {
267266 def branch = ' gh-pages'
268267 sh ' make doxygen'
0 commit comments