Merge pull request 'fix: #8698 Jenkins find use TARGET_BRANCH' (!1728) from warmFix_gitFetch_gitDiff into test
gitea/salix-front/pipeline/head This commit looks good Details

Reviewed-on: #1728
Reviewed-by: Jon Elias <jon@verdnatura.es>
This commit is contained in:
Alex Moreno 2025-04-22 08:02:29 +00:00
commit 2d60ed5522
2 changed files with 4 additions and 1 deletions

2
Jenkinsfile vendored
View File

@ -125,7 +125,7 @@ pipeline {
sh "docker-compose ${env.COMPOSE_PARAMS} pull db"
sh "docker-compose ${env.COMPOSE_PARAMS} up -d"
def modules = sh(script: 'node test/cypress/docker/find/find.js', returnStdout: true).trim()
def modules = sh(script: "node test/cypress/docker/find/find.js ${env.COMPOSE_TAG}", returnStdout: true).trim()
echo "E2E MODULES: ${modules}"
image.inside("--network ${env.COMPOSE_PROJECT}_default -e CI -e TZ --init") {
sh "sh test/cypress/docker/cypressParallel.sh 1 '${modules}'"

View File

@ -6,6 +6,9 @@ const FINDED_PATHS = ['src', E2E_PATH];
function getGitDiff(options) {
const TARGET_BRANCH = options[2] || 'dev';
execSync(`git fetch origin ${TARGET_BRANCH}`, {
encoding: 'utf-8',
});
const diff = execSync(`git diff --name-only origin/${TARGET_BRANCH}`, {
encoding: 'utf-8',
});