e2e: dump error-context.md to log on failure + bump upload-artifact
CI / Test (server-http) (pull_request) Successful in 7s
CI / Test (store) (pull_request) Successful in 6s
CI / Test (rest) (pull_request) Successful in 13s
CI / Build (windows/amd64) (pull_request) Successful in 9s
CI / Build (linux/arm64) (pull_request) Successful in 8s
CI / Lint (pull_request) Successful in 19s
CI / Build (linux/amd64) (pull_request) Successful in 15s
e2e / Playwright vs docker-compose (pull_request) Failing after 3m37s
CI / Test (server-http) (pull_request) Successful in 7s
CI / Test (store) (pull_request) Successful in 6s
CI / Test (rest) (pull_request) Successful in 13s
CI / Build (windows/amd64) (pull_request) Successful in 9s
CI / Build (linux/arm64) (pull_request) Successful in 8s
CI / Lint (pull_request) Successful in 19s
CI / Build (linux/amd64) (pull_request) Successful in 15s
e2e / Playwright vs docker-compose (pull_request) Failing after 3m37s
The Playwright run produces error-context.md per failed test with a full DOM snapshot — useful for triaging UI test failures without round-tripping through downloaded artifacts. Cat it into the workflow log on failure. Also bump actions/upload-artifact v3 → v4. v3 uploads still return success on this Gitea runner but the artifacts don't surface through the API or UI; v4 is the correct version per the workflow header note.
This commit is contained in:
@@ -96,6 +96,19 @@ jobs:
|
||||
docker cp e2e-pw:/work/playwright-report/. e2e/playwright/playwright-report/ || true
|
||||
docker cp e2e-pw:/work/test-results/. e2e/playwright/test-results/ || true
|
||||
|
||||
- name: Show Playwright failure context (on failure)
|
||||
if: failure()
|
||||
run: |
|
||||
set +e
|
||||
shopt -s nullglob globstar
|
||||
for f in e2e/playwright/test-results/**/error-context.md; do
|
||||
echo "::group::$f"
|
||||
cat "$f"
|
||||
echo "::endgroup::"
|
||||
done
|
||||
echo "Failure attachments (download via the playwright-report artifact):"
|
||||
find e2e/playwright/test-results \( -name '*.png' -o -name '*.webm' -o -name 'trace.zip' \) -printf ' %p\n' | sort
|
||||
|
||||
- name: Compose logs (on failure)
|
||||
if: failure()
|
||||
run: |
|
||||
@@ -105,7 +118,7 @@ jobs:
|
||||
|
||||
- name: Upload Playwright report (on failure)
|
||||
if: failure()
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: playwright-report
|
||||
path: |
|
||||
|
||||
Reference in New Issue
Block a user