From 51be681758d6a19ad57b4e1b3fa5c1bc5d30c2ea Mon Sep 17 00:00:00 2001 From: Michael Li Date: Mon, 13 Apr 2026 15:08:21 -0400 Subject: [PATCH] chore: Always run end-to-end tests (#3234) * chore: Always run e2e tests * chore: Parallelize browsers --- .github/workflows/test-e2e-admin-ui.yaml | 26 +++++++++--------------- .github/workflows/test-e2e-desktop.yaml | 9 +------- 2 files changed, 11 insertions(+), 24 deletions(-) diff --git a/.github/workflows/test-e2e-admin-ui.yaml b/.github/workflows/test-e2e-admin-ui.yaml index 2c904d6a1..8caac9eee 100644 --- a/.github/workflows/test-e2e-admin-ui.yaml +++ b/.github/workflows/test-e2e-admin-ui.yaml @@ -3,13 +3,6 @@ name: Test E2E Admin UI on: pull_request: types: [labeled, opened, synchronize, reopened] - paths: - - 'ui/admin/**' - - 'e2e-tests/*' - - 'e2e-tests/api-client/**' - - 'e2e-tests/helpers/**' - - 'e2e-tests/admin/**' - - '.github/workflows/test-e2e-admin-ui.yaml' workflow_dispatch: inputs: boundary-enterprise-branch: @@ -33,6 +26,8 @@ jobs: runs-on: ${{ fromJSON(vars.RUNNER_UBUNTU_22) }} strategy: matrix: + boundary_edition: [community, enterprise] + browser: [chromium, firefox, webkit] include: - boundary_edition: community github_repo: hashicorp/boundary @@ -48,6 +43,11 @@ jobs: enos_scenario: e2e_ui_docker_ent test_command: admin:ent:docker boundary_branch: ${{ github.event.inputs.boundary-enterprise-branch || 'main' }} + # in boundary-ui-enterprise, only run tests on chromium because playwright dependencies can't + # be installed on self-hosted runners due to permission issues + exclude: + - browser: ${{ github.repository == 'hashicorp/boundary-ui-enterprise' && 'firefox' }} + - browser: ${{ github.repository == 'hashicorp/boundary-ui-enterprise' && 'webkit' }} fail-fast: false env: ENOS_VAR_e2e_debug_no_run: true @@ -217,19 +217,13 @@ jobs: run: | source <(bash ./support/src/${{matrix.folder_name}}/enos/scripts/test_e2e_env.sh) cd e2e-tests - if [[ "${{ github.repository }}" == "hashicorp/boundary-ui" ]]; then - pnpm run ${{ matrix.test_command }} --reporter=html - elif [[ "${{ github.repository }}" == "hashicorp/boundary-ui-enterprise" ]]; then - # only run tests on chromium because playwright dependencies can't - # be installed to support other browsers - pnpm run ${{ matrix.test_command }} --project=chromium --reporter=html - fi + pnpm run ${{ matrix.test_command }} --project=${{ matrix.browser}} --reporter=html - name: Upload Playwright report if: ${{ failure() }} uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0 with: - name: playwright-report-${{ matrix.boundary_edition }} + name: playwright-report-${{ matrix.boundary_edition }}-${{ matrix.browser }} path: e2e-tests/playwright-report - name: Clean up test infra @@ -249,4 +243,4 @@ jobs: token: ${{ secrets.SLACK_BOT_TOKEN }} payload: | channel: ${{ secrets.SLACK_CHANNEL_ID }} - text: ":x: admin ui e2e tests failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\n*Branch:* ${{ github.repository }}:${{ github.head_ref }}" + text: ":x: admin ui e2e tests (${{ matrix.boundary_edition }}:${{ matrix.browser }}) failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\n*Branch:* ${{ github.repository }}:${{ github.head_ref || github.ref_name }}" diff --git a/.github/workflows/test-e2e-desktop.yaml b/.github/workflows/test-e2e-desktop.yaml index ed1a7065b..53f23273f 100644 --- a/.github/workflows/test-e2e-desktop.yaml +++ b/.github/workflows/test-e2e-desktop.yaml @@ -3,13 +3,6 @@ name: Test E2E Desktop Client on: pull_request: types: [labeled, opened, synchronize, reopened] - paths: - - 'ui/desktop/**' - - 'e2e-tests/*' - - 'e2e-tests/api-client/**' - - 'e2e-tests/helpers/**' - - 'e2e-tests/desktop/**' - - '.github/workflows/test-e2e-desktop.yaml' workflow_dispatch: inputs: boundary-enterprise-branch: @@ -187,4 +180,4 @@ jobs: token: ${{ secrets.SLACK_BOT_TOKEN }} payload: | channel: ${{ secrets.SLACK_CHANNEL_ID }} - text: ":x: desktop client e2e tests failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\n*Branch:* ${{ github.repository }}:${{ github.head_ref }}" + text: ":x: desktop client e2e tests failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\n*Branch:* ${{ github.repository }}:${{ github.head_ref || github.ref_name }}"