This repository was archived by the owner on Aug 13, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathJenkinsfile
More file actions
50 lines (50 loc) · 2.11 KB
/
Jenkinsfile
File metadata and controls
50 lines (50 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
pipeline {
agent {
dockerfile {
filename 'Dockerfile'
args '--gpus all -u root'
}
}
stages {
stage('Build') {
steps {
sh 'pip3 install -r requirements.txt'
sh 'pip3 install -e .'
}
}
stage('Pylint') {
steps {
sh 'pylint -ry --output-format=parseable --exit-zero ./pyqmri > pylint.log'
}
}
stage('Unittests') {
steps {
sh 'pytest --junitxml results_unittests_LinOp.xml --cov=pyqmri test/unittests/test_LinearDataOperator.py'
sh 'coverage xml -o coverage_unittest_LinOp.xml'
sh 'pytest --junitxml results_unittests_grad.xml --cov=pyqmri test/unittests/test_gradient.py'
sh 'coverage xml -o coverage_unittest_grad.xml'
sh 'pytest --junitxml results_unittests_symgrad.xml --cov=pyqmri test/unittests/test_symmetrized_gradient.py'
sh 'coverage xml -o coverage_unittest_symgrad.xml'
}
}
stage('Integrationtests') {
steps {
sh 'ipcluster start&'
sh 'pytest --junitxml results_integrationtests_single_slice.xml --cov=pyqmri --integration-cover test/integrationtests/test_integration_test_single_slice.py'
sh 'coverage xml -o coverage_integrationtest_single_slice.xml'
sh 'pytest --junitxml results_integrationtests_multi_slice.xml --cov=pyqmri --integration-cover test/integrationtests/test_integration_test_multi_slice.py'
sh 'coverage xml -o coverage_integrationtest_multi_slice.xml'
sh 'ipcluster stop&'
}
}
}
post {
always {
cobertura coberturaReportFile: 'coverage_unittest_LinOp.xml, coverage_unittest_grad.xml, coverage_unittest_symgrad.xml, coverage_integrationtest_single_slice.xml, coverage_integrationtest_multi_slice.xml', enableNewApi: true
junit 'results*.xml'
recordIssues enabledForFailure: true, tool: pyLint(pattern: 'pylint.log')
step([$class: 'GitHubCommitStatusSetter', statusBackrefSource: [$class: 'ManuallyEnteredBackrefSource', backref: 'https://00c8da69b5ae.ngrok.io:8090/job/PyQMRI_public/job/JOSS_pub/42/display/redirect']])
cleanWs()
}
}
}