[ACS-10876] ACA e2e playwright automated test for Firefox Edge and Safari (#4952)

* [ACS-10876] playwright config changes to support multi browser

* [ACS-10876]workflow temp changes to enable all browser run

* [ACS-10876]workflow issue fix

* [ACS-10876]workflow issue fix

* [ACS-10876]workflow issue fix

* [ACS-10876]workflow issue fix

* [ACS-10876]fix report issue and webkit dep issue

* [ACS-10876]fix report issue and exclude test logic

* [ACS-10876]playwright browser setup change

* [ACS-10876]small fixes

* [ACS-10876]restore only run on pull request schedule job

* [ACS-10876]sonar cloud issue fix

* [ACS-10876]make chromium for pr run and chrome browser for scheduled run

* [ACS-10876]sonar cloud issue fix

* [ACS-10876]sonar cloud issue fix and small improvement
This commit is contained in:
Akash Rathod
2025-12-23 12:48:17 +01:00
committed by GitHub
parent 3aa3167010
commit 53f19f7935
46 changed files with 742 additions and 312 deletions
@@ -21,6 +21,7 @@ runs:
shell: bash
env:
OPTIONS: ${{ inputs.options }}
PLAYWRIGHT_BROWSER: ${{ env.PLAYWRIGHT_BROWSER || 'chromium' }}
run: |
npm start > /dev/null &\
@@ -31,5 +32,5 @@ runs:
done
printf "\nApplication is ready.\n"
echo "Running playwright tests with options $OPTIONS"
echo "Running playwright tests with options $OPTIONS on browser ${PLAYWRIGHT_BROWSER}"
E2E_TARGET=$OPTIONS npm run ci:e2e
+19 -4
View File
@@ -123,13 +123,16 @@ jobs:
e2es-playwright:
needs: [lint, build, unit-tests]
name: 'E2E Playwright - ${{ matrix.e2e-suites.name }}'
name: E2E | ${{ matrix.browser || 'chromium' }} | ${{ matrix.e2e-suites.name }} | Playwright
runs-on: ubuntu-24.04
env:
NODE_OPTIONS: --dns-result-order=ipv4first
PLAYWRIGHT_BROWSER: ${{ matrix.browser }}
strategy:
fail-fast: false
matrix:
# For scheduled runs, include all browsers; for PR runs, only Chromium
browser: ${{ github.event_name != 'pull_request' && fromJSON('["chrome", "firefox", "webkit", "msedge"]') || fromJSON('["chromium"]') }}
e2e-suites:
- name: "create-actions"
id: 1
@@ -199,7 +202,7 @@ jobs:
uses: Alfresco/alfresco-build-tools/.github/actions/kubectl-keep-nslogs@b51dfeef6bda4a506778050a1c0e53eed440598c # v11.0.1
with:
log_retention: 7
log_name_identifier: "logs-${{ matrix.e2e-suites.name }}"
log_name_identifier: "logs-${{ matrix.browser || 'chromium' }}-${{ matrix.e2e-suites.name }}"
- name: Before install
uses: ./.github/actions/before-install
@@ -217,15 +220,27 @@ jobs:
- name: Before e2e
uses: ./.github/actions/before-e2e
- name: Before playwright
- name: Before playwright (Chromium for PR)
if: ${{ github.event_name == 'pull_request' }}
run: npm run ci:playwright:install
- name: Before playwright (all browsers)
if: ${{ github.event_name != 'pull_request' }}
run: npm run ci:playwright:install:all
- name: Install Playwright system dependencies
# Install system dependencies required for all browsers (especially WebKit on Linux)
if: ${{ github.event_name != 'pull_request' }}
run: npx playwright install-deps
- name: Run e2e playwright
uses: ./.github/actions/run-e2e-playwright
with:
options: "${{ matrix.e2e-suites.name }}"
artifact-name: ${{ matrix.e2e-suites.name }}
artifact-name: "${{ matrix.browser || 'chromium' }}-${{ matrix.e2e-suites.name }}"
test-runner: playwright
env:
PLAYWRIGHT_BROWSER: ${{ matrix.browser || 'chromium' }}
- name: Debug Ingress Controller Logs
if: always() && steps.deploy-local-acs.outcome == 'success'