update jenkinsfile
Some checks failed
Rust Verify / Verify occurred while executing withChecks step.
Some checks failed
Rust Verify / Verify occurred while executing withChecks step.
This commit is contained in:
parent
b07f2f377a
commit
d46f447273
49
files/config/Jenkinsfile
vendored
49
files/config/Jenkinsfile
vendored
@ -2,31 +2,40 @@ pipeline {
|
||||
agent any
|
||||
|
||||
stages {
|
||||
stage('Setup') {
|
||||
stage('Verify') {
|
||||
steps {
|
||||
giteaStatus status: 'PENDING', context: 'ci/jenkins'
|
||||
sh '''
|
||||
set -e
|
||||
rustup component add clippy rustfmt
|
||||
'''
|
||||
withChecks(name: 'Rust Verify', includeStage: true) {
|
||||
sh '''
|
||||
set -e
|
||||
rustup component add clippy rustfmt llvm-tools-preview
|
||||
cargo fmt --all -- --check
|
||||
cargo clippy --all-targets --all-features -- -D warnings
|
||||
'''
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('CI') {
|
||||
steps {
|
||||
sh '''
|
||||
set -e
|
||||
make ci
|
||||
'''
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
post {
|
||||
success {
|
||||
giteaStatus status: 'SUCCESS', context: 'ci/jenkins'
|
||||
stage('Test + Coverage') {
|
||||
steps {
|
||||
withChecks(name: 'Rust Test', includeStage: true) {
|
||||
sh '''
|
||||
set -e
|
||||
cargo install cargo-llvm-cov --locked || true
|
||||
cargo llvm-cov --all-features --workspace --cobertura --output-path coverage.xml
|
||||
'''
|
||||
}
|
||||
}
|
||||
}
|
||||
failure {
|
||||
giteaStatus status: 'FAILURE', context: 'ci/jenkins'
|
||||
|
||||
stage('Reports') {
|
||||
steps {
|
||||
recordCoverage(
|
||||
tools: [[parser: 'COBERTURA', pattern: 'coverage.xml']],
|
||||
id: 'rust-coverage',
|
||||
name: 'Rust Coverage',
|
||||
sourceCodeRetention: 'EVERY_BUILD'
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user