Adjust to copy the report
testing/ogcore-api/pipeline/pr-main This commit looks good Details
testing/ogcore-api/pipeline/head Something is wrong with the build of this commit Details

helpers/ci-integration
Nicolas Arenas 2024-09-25 18:42:18 +02:00
parent ec86e867c3
commit 440a5f8bf1
1 changed files with 6 additions and 3 deletions

9
Jenkinsfile vendored
View File

@ -19,12 +19,15 @@ pipeline {
sh 'docker exec ogcore-php php bin/console lexik:jwt:generate-keypair --overwrite'
sh 'docker exec ogcore-php php bin/console doctrine:migrations:migrate --no-interaction'
sh 'docker exec ogcore-php php bin/console doctrine:fixtures:load --no-interaction'
// Create report directory
sh 'docker exec ogcore-php mkdir -p /report'
}
}
stage('Tests') {
steps {
// Run tests
sh 'docker compose exec php bin/phpunit --log-junit phpunit.xml'
sh 'docker compose exec php bin/phpunit --log-junit /report/phpunit.xml'
sh 'docker cp ogcore-php:/report/phpunit.xml .'
}
}
}
@ -36,8 +39,8 @@ pipeline {
tools: [ PHPUnit(pattern: 'phpunit.xml') ]
)
// Remove containers
sh 'docker compose down'
sh 'docker compose rm -f'
sh 'docker compose -f docker-compose-ci.yaml down'
sh 'docker compose -f docker-compose-ci.yaml rm -f'
}
}
}