refactor: refs #6695 streamline Cypress test execution and remove deprecated configurations
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
This commit is contained in:
parent
87c6feb0b5
commit
de7e264391
|
@ -118,7 +118,6 @@ pipeline {
|
||||||
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 || true'
|
|
||||||
sh '''#!/bin/bash
|
sh '''#!/bin/bash
|
||||||
source test/cypress/cypressParallel.sh
|
source test/cypress/cypressParallel.sh
|
||||||
cypressParallel 2 || true
|
cypressParallel 2 || true
|
||||||
|
|
|
@ -69,13 +69,5 @@ export default defineConfig({
|
||||||
...timeouts,
|
...timeouts,
|
||||||
includeShadowDom: true,
|
includeShadowDom: true,
|
||||||
waitForAnimations: true,
|
waitForAnimations: true,
|
||||||
setupNodeEvents(on, config) {
|
|
||||||
on('before:browser:launch', (browser = {}, launchOptions) => {
|
|
||||||
launchOptions.args.push('--disable-gpu');
|
|
||||||
launchOptions.args.push('--no-sandbox');
|
|
||||||
|
|
||||||
return launchOptions;
|
|
||||||
});
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,9 +1,4 @@
|
||||||
cypressParallel() {
|
cypressParallel() {
|
||||||
TEST_PATHS=(
|
|
||||||
'test/cypress/integration/client/*.spec.js'
|
|
||||||
)
|
|
||||||
# printf "%s\n" "${TEST_PATHS[@]}" | xargs -P $1 -I {} sh -c 'xvfb-run -a cypress run --headless --browser chromium --spec {}'
|
|
||||||
# find 'test/cypress/integration' -name "*.spec.js" | xargs -P "$1" -I {} sh -c 'echo "🔷 {}" && xvfb-run -a cypress run --headless --browser chromium --spec "{}" --quiet > /dev/null 2>&1'
|
|
||||||
find 'test/cypress/integration' -mindepth 1 -maxdepth 1 -type d | xargs -P "$1" -I {} sh -c 'echo "🔷 {}" && xvfb-run -a cypress run --headless --browser chromium --spec "{}" --quiet > /dev/null 2>&1'
|
find 'test/cypress/integration' -mindepth 1 -maxdepth 1 -type d | xargs -P "$1" -I {} sh -c 'echo "🔷 {}" && xvfb-run -a cypress run --headless --browser chromium --spec "{}" --quiet > /dev/null 2>&1'
|
||||||
wait
|
wait
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
CYPRESS_SPEC_FOLDER="test/cypress/integration"
|
|
||||||
cleanup() {
|
cleanup() {
|
||||||
docker-compose -p e2e --project-directory . -f test/cypress/docker-compose.yml down || true
|
docker-compose -p e2e --project-directory . -f test/cypress/docker-compose.yml down || true
|
||||||
}
|
}
|
||||||
|
@ -13,13 +12,16 @@ rm -rf test/cypress/reports
|
||||||
rm -rf junit
|
rm -rf junit
|
||||||
|
|
||||||
#RUN
|
#RUN
|
||||||
CI=true TZ=Europe/Madrid docker-compose -p e2e --project-directory . -f test/cypress/docker-compose.yml up -d
|
export CI=true
|
||||||
|
export TZ=Europe/Madrid
|
||||||
|
|
||||||
|
docker-compose -p e2e --project-directory . -f test/cypress/docker-compose.yml up -d
|
||||||
|
|
||||||
docker run -it --rm \
|
docker run -it --rm \
|
||||||
-v "$(pwd)":/app \
|
-v "$(pwd)":/app \
|
||||||
-e CI=true \
|
|
||||||
-e TZ=Europe/Madrid \
|
|
||||||
--network e2e_default \
|
--network e2e_default \
|
||||||
|
-e CI \
|
||||||
|
-e TZ \
|
||||||
lilium-dev \
|
lilium-dev \
|
||||||
bash -c '
|
bash -c '
|
||||||
source test/cypress/cypressParallel.sh
|
source test/cypress/cypressParallel.sh
|
||||||
|
|
Loading…
Reference in New Issue