Reduce E2E output to Playwright logs
This commit is contained in:
parent
7ffec2c324
commit
99d2efac6c
2 changed files with 6 additions and 2 deletions
|
|
@ -72,12 +72,13 @@ e2e-pleroma:
|
|||
DOCKER_HOST: tcp://docker:2375
|
||||
DOCKER_TLS_CERTDIR: ""
|
||||
DOCKER_DRIVER: overlay2
|
||||
COMPOSE_MENU: "false"
|
||||
script:
|
||||
- docker version
|
||||
- docker compose version
|
||||
- echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" --password-stdin "$CI_REGISTRY"
|
||||
- export PLEROMA_IMAGE="${PLEROMA_IMAGE:-$CI_REGISTRY/pleroma/pleroma:stable}"
|
||||
- docker compose -f docker-compose.e2e.yml up --build --remove-orphans --abort-on-container-exit --exit-code-from e2e
|
||||
- docker compose -f docker-compose.e2e.yml up --build --remove-orphans --attach e2e --no-log-prefix --abort-on-container-exit --exit-code-from e2e
|
||||
after_script:
|
||||
- docker compose -f docker-compose.e2e.yml cp e2e:/app/test/e2e-playwright/test-results test/e2e-playwright/test-results || true
|
||||
- docker compose -f docker-compose.e2e.yml cp e2e:/app/test/e2e-playwright/playwright-report test/e2e-playwright/playwright-report || true
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ set -u
|
|||
|
||||
COMPOSE_FILE="docker-compose.e2e.yml"
|
||||
|
||||
: "${COMPOSE_MENU:=false}"
|
||||
: "${PLEROMA_IMAGE:=git.pleroma.social:5050/pleroma/pleroma:stable}"
|
||||
: "${E2E_ADMIN_USERNAME:=admin}"
|
||||
: "${E2E_ADMIN_PASSWORD:=adminadmin}"
|
||||
|
|
@ -18,11 +19,13 @@ cleanup
|
|||
trap 'cleanup; exit 130' INT TERM
|
||||
|
||||
set +e
|
||||
docker compose -f "$COMPOSE_FILE" up --build --remove-orphans --abort-on-container-exit --exit-code-from e2e
|
||||
COMPOSE_MENU="$COMPOSE_MENU" docker compose -f "$COMPOSE_FILE" up --build --remove-orphans --attach e2e --no-log-prefix --abort-on-container-exit --exit-code-from e2e
|
||||
result="$?"
|
||||
set -e
|
||||
|
||||
if [ "$result" -ne 0 ]; then
|
||||
mkdir -p test/e2e-playwright/test-results
|
||||
docker compose -f "$COMPOSE_FILE" logs --no-color pleroma db > test/e2e-playwright/test-results/docker-compose.log 2>/dev/null || true
|
||||
docker compose -f "$COMPOSE_FILE" cp e2e:/app/test/e2e-playwright/test-results test/e2e-playwright/test-results >/dev/null 2>&1 || true
|
||||
docker compose -f "$COMPOSE_FILE" cp e2e:/app/test/e2e-playwright/playwright-report test/e2e-playwright/playwright-report >/dev/null 2>&1 || true
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue