mirror of
https://github.com/clearlinux/graphene.git
synced 2026-09-06 13:51:28 +00:00
[CI] Refactor common stage-test
Also remove central artifacts.jenkinsfile, which in hindsight was a bad, if-ridden idea. The try/finally should be exactly around the sh block which generates the junit file in question.
This commit is contained in:
@@ -1,4 +0,0 @@
|
||||
always {
|
||||
junit 'Pal/regression/pal-regression.xml'
|
||||
junit 'LibOS/shim/test/regression/libos-regression.xml'
|
||||
}
|
||||
@@ -1,19 +1,4 @@
|
||||
stage('test') {
|
||||
sh '''
|
||||
cd Pal/regression
|
||||
make ${MAKEOPTS} all
|
||||
make regression
|
||||
'''
|
||||
sh '''
|
||||
cd LibOS/shim/test/regression
|
||||
make ${MAKEOPTS} all
|
||||
make regression
|
||||
'''
|
||||
sh '''
|
||||
cd LibOS/shim/test/fs
|
||||
make ${MAKEOPTS} all
|
||||
make test
|
||||
'''
|
||||
stage('test-direct') {
|
||||
try {
|
||||
sh '''
|
||||
cd LibOS/shim/test/ltp
|
||||
@@ -1,4 +1,4 @@
|
||||
stage('test') {
|
||||
stage('test-sgx') {
|
||||
timeout(time: 5, unit: 'MINUTES') {
|
||||
sh '''
|
||||
cd Examples/python-simple
|
||||
@@ -1,30 +0,0 @@
|
||||
stage('test') {
|
||||
sh '''
|
||||
make ${MAKEOPTS} test
|
||||
make ${MAKEOPTS} sgx-tokens
|
||||
make ${MAKEOPTS} -C Pal/src/host/Linux-SGX/tools install \
|
||||
PREFIX=../../../../../../LibOS/shim/test/fs
|
||||
'''
|
||||
timeout(time: 15, unit: 'MINUTES') {
|
||||
sh '''
|
||||
cd Pal/regression
|
||||
make -j8 SGX=1 all sgx-tokens
|
||||
make SGX=1 KEEP_LOG=1 regression
|
||||
'''
|
||||
}
|
||||
timeout(time: 15, unit: 'MINUTES') {
|
||||
sh '''
|
||||
cd LibOS/shim/test/regression
|
||||
make clean SGX=1 # re-build with ra_client_spid set
|
||||
make -j8 SGX=1 RA_CLIENT_SPID=${ra_client_spid} all sgx-tokens
|
||||
make SGX=1 regression
|
||||
'''
|
||||
}
|
||||
timeout(time: 5, unit: 'MINUTES') {
|
||||
sh '''
|
||||
cd LibOS/shim/test/fs
|
||||
make -j8 SGX=1 all sgx-tokens
|
||||
make SGX=1 test
|
||||
'''
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,56 @@
|
||||
stage('test') {
|
||||
sh '''
|
||||
make ${MAKEOPTS} test
|
||||
if test -n "$SGX"
|
||||
then
|
||||
make ${MAKEOPTS} sgx-tokens
|
||||
make ${MAKEOPTS} -C Pal/src/host/Linux-SGX/tools install \
|
||||
PREFIX=../../../../../../LibOS/shim/test/fs
|
||||
fi
|
||||
'''
|
||||
|
||||
timeout(time: 15, unit: 'MINUTES') {
|
||||
try {
|
||||
sh '''
|
||||
cd Pal/regression
|
||||
make ${MAKEOPTS} all
|
||||
if test -n "$SGX"
|
||||
then
|
||||
make ${MAKEOPTS} sgx-tokens
|
||||
fi
|
||||
make regression
|
||||
'''
|
||||
} finally {
|
||||
junit 'Pal/regression/pal-regression.xml'
|
||||
}
|
||||
}
|
||||
|
||||
timeout(time: 15, unit: 'MINUTES') {
|
||||
try {
|
||||
sh '''
|
||||
cd LibOS/shim/test/regression
|
||||
make clean # re-build with ra_client_spid set
|
||||
make ${MAKEOPTS} RA_CLIENT_SPID=${ra_client_spid} all
|
||||
if test -n "$SGX"
|
||||
then
|
||||
make ${MAKEOPTS} RA_CLIENT_SPID=${ra_client_spid} sgx-tokens
|
||||
fi
|
||||
make regression
|
||||
'''
|
||||
} finally {
|
||||
junit 'LibOS/shim/test/regression/libos-regression.xml'
|
||||
}
|
||||
}
|
||||
|
||||
timeout(time: 5, unit: 'MINUTES') {
|
||||
sh '''
|
||||
cd LibOS/shim/test/fs
|
||||
make ${MAKEOPTS} all
|
||||
if test -n "$SGX"
|
||||
then
|
||||
make ${MAKEOPTS} sgx-tokens
|
||||
fi
|
||||
make test
|
||||
'''
|
||||
}
|
||||
}
|
||||
@@ -12,11 +12,8 @@ node('nonsgx_slave') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-nosgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-all-nosgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-test-direct.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,11 +12,8 @@ node('nonsgx_slave') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-nosgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-all-nosgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-test-direct.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,11 +12,8 @@ node('nonsgx_slave') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-nosgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-all-nosgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-test-direct.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,11 +12,8 @@ node('nonsgx_slave') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-nosgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-all-nosgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-test-direct.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,11 +13,7 @@ node('sgx_slave_2.6') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-sgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-apps-sgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test-sgx.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,11 +13,7 @@ node('sgx_slave_2.6') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-sgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-simple-sgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,11 +13,7 @@ node('sgx_slave_2.6') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-sgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-apps-sgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test-sgx.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,11 +13,7 @@ node('sgx_slave_2.6') {
|
||||
load '.ci/lib/stage-lint.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check-prepare.jenkinsfile'
|
||||
load '.ci/lib/stage-build-sgx.jenkinsfile'
|
||||
try {
|
||||
load '.ci/lib/stage-test-simple-sgx.jenkinsfile'
|
||||
} finally {
|
||||
load '.ci/lib/artifacts.jenkinsfile'
|
||||
}
|
||||
load '.ci/lib/stage-test.jenkinsfile'
|
||||
load '.ci/lib/stage-clean-check.jenkinsfile'
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user