38 lines
1.9 KiB
Groovy
38 lines
1.9 KiB
Groovy
def tests = ['primitives', 'addressof', 'callback']
|
|
|
|
pipeline {
|
|
agent any
|
|
|
|
options {
|
|
disableConcurrentBuilds()
|
|
buildDiscarder(logRotator(numToKeepStr: '10', artifactNumToKeepStr: '10'))
|
|
}
|
|
|
|
stages {
|
|
stage('Tests') {
|
|
steps {
|
|
script {
|
|
def implementations = sh(script: 'docker run retropikzel1/compile-r7rs:chibi sh -c "compile-r7rs --list-r7rs-schemes"', returnStdout: true).split()
|
|
|
|
implementations.each { implementation->
|
|
tests.each { test ->
|
|
stage("${implementation} ${test}") {
|
|
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
|
sh "docker build --build-arg COMPILE_R7RS=${implementation} --tag=r7rs-pffi-test-${implementation} -f dockerfiles/Dockerfile.test ."
|
|
sh "docker run -v ${WORKSPACE}:/workdir -w /workdir -t r7rs-pffi-test-${implementation} sh -c \"make COMPILE_R7RS=${implementation} TESTNAME=primitives test-compile-r7rs\""
|
|
}
|
|
}
|
|
}
|
|
stage("${implementation} snow-chibi install test") {
|
|
catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') {
|
|
sh "docker build --build-arg COMPILE_R7RS=${implementation} --tag=r7rs-pffi-test-${implementation} -f dockerfiles/Dockerfile.snow-chibi-install-test ."
|
|
sh "docker run -v ${WORKSPACE}:/workdir -w /workdir -t r7rs-pffi-test-${implementation} sh -c \"make clean-package package && snow-chibi install --impls=foreign-c-0.10.0.tgz && ${implementation} tests/hello.scm\""
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|