ci: refs #6695 comment out test stages in Jenkinsfile
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Alex Moreno 2025-02-21 13:46:35 +01:00
parent 3e2d7fad61
commit e0d0830793
1 changed files with 51 additions and 50 deletions

101
Jenkinsfile vendored
View File

@ -80,58 +80,59 @@ pipeline {
} }
steps { steps {
sh 'pnpm install --prefer-offline' sh 'pnpm install --prefer-offline'
echo CHANGE_TARGET
} }
} }
stage('Test') { // stage('Test') {
when { // when {
expression { !PROTECTED_BRANCH } // expression { !PROTECTED_BRANCH }
} // }
environment { // environment {
NODE_ENV = '' // NODE_ENV = ''
CI = 'true' // CI = 'true'
TZ = 'Europe/Madrid' // TZ = 'Europe/Madrid'
} // }
parallel { // parallel {
stage('Unit') { // stage('Unit') {
steps { // steps {
sh 'pnpm run test:unit:ci' // sh 'pnpm run test:unit:ci'
} // }
post { // post {
always { // always {
junit( // junit(
testResults: 'junit/vitest.xml', // testResults: 'junit/vitest.xml',
allowEmptyResults: true // allowEmptyResults: true
) // )
} // }
} // }
} // }
stage('E2E') { // stage('E2E') {
environment { // environment {
CREDENTIALS = credentials('docker-registry') // CREDENTIALS = credentials('docker-registry')
COMPOSE_PROJECT = "${PROJECT_NAME}-${env.BUILD_ID}" // COMPOSE_PROJECT = "${PROJECT_NAME}-${env.BUILD_ID}"
COMPOSE_PARAMS = "-p ${env.COMPOSE_PROJECT} -f test/cypress/docker-compose.yml --project-directory ." // COMPOSE_PARAMS = "-p ${env.COMPOSE_PROJECT} -f test/cypress/docker-compose.yml --project-directory ."
} // }
steps { // steps {
script { // script {
def image = docker.build('lilium-dev', '-f docs/Dockerfile.dev docs') // def image = docker.build('lilium-dev', '-f docs/Dockerfile.dev docs')
sh "docker-compose ${env.COMPOSE_PARAMS} up -d" // sh "docker-compose ${env.COMPOSE_PARAMS} up -d"
image.inside("--network ${env.COMPOSE_PROJECT}_default -e CI -e TZ") { // image.inside("--network ${env.COMPOSE_PROJECT}_default -e CI -e TZ") {
sh 'cypress run --browser chromium' // sh 'cypress run --browser chromium'
} // }
} // }
} // }
post { // post {
always { // always {
sh "docker-compose ${env.COMPOSE_PARAMS} down" // sh "docker-compose ${env.COMPOSE_PARAMS} down"
junit( // junit(
testResults: 'junit/e2e.xml', // testResults: 'junit/e2e.xml',
allowEmptyResults: true // allowEmptyResults: true
) // )
} // }
} // }
} // }
} // }
} // }
stage('Build') { stage('Build') {
when { when {
expression { PROTECTED_BRANCH } expression { PROTECTED_BRANCH }