Skip to content

chore(deps): update dependency phpunit/php-code-coverage to v11 #3504

chore(deps): update dependency phpunit/php-code-coverage to v11

chore(deps): update dependency phpunit/php-code-coverage to v11 #3504

Workflow file for this run

name: E2E Testing
on:
push:
branches:
- master
pull_request:
workflow_dispatch:
concurrency:
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.ref }}
permissions:
contents: none
jobs:
e2e:
name: "Run E2E tests (use wordpress:${{ matrix.wordpress }} image)"
permissions:
contents: read
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
wordpress:
- php8.0
- php8.1
- php8.2
- beta-php8.0
- beta-php8.1
- beta-php8.2
steps:
- name: Harden Runner
uses: step-security/harden-runner@0080882f6c36860b6ba35c610c98ce87d4e2f26f # v2.10.2
with:
disable-file-monitoring: true
egress-policy: block
allowed-endpoints: >
api.github.com:443
api.wordpress.org:443
auth.docker.io:443
azure.archive.ubuntu.com:80
downloads.wordpress.org:443
github.com:443
objects.githubusercontent.com:443
packagist.org:443
pecl.php.net:443
pecl.php.net:80
phar.phpunit.de:443
planet.wordpress.org:443
playwright.azureedge.net:443
production.cloudflare.docker.com:443
registry-1.docker.io:443
registry.npmjs.org:443
repo.packagist.org:443
secure.gravatar.com:443
wordpress.org:443
- name: Checkout source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Node.js environment
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: lts/*
cache: npm
- name: Install dependencies
run: npm ci
- name: Set up PHP
uses: shivammathur/setup-php@c541c155eee45413f5b09a52248675b1a2575231 # 2.31.1
- name: Install Composer Dependencies
uses: ramsey/composer-install@57532f8be5bda426838819c5ee9afb8af389d51a # 3.0.0
- name: Install Playwright
run: npx playwright install chromium
- name: Run Playwright E2E tests
run: npm run test:e2e
env:
WP_VERSION: ${{ matrix.wordpress }}
- name: Upload test results
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
if: failure()
with:
name: playwright-test-results-${{ matrix.wordpress }}
path: test-results/
retention-days: 3
e2e-bundle:
name: Run E2E tests on the generated plugin
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: Harden Runner
uses: step-security/harden-runner@0080882f6c36860b6ba35c610c98ce87d4e2f26f # v2.10.2
with:
disable-file-monitoring: true
egress-policy: block
allowed-endpoints: >
api.github.com:443
api.wordpress.org:443
auth.docker.io:443
downloads.wordpress.org:443
github.com:443
objects.githubusercontent.com:443
packagist.org:443
repo.packagist.org:443
pecl.php.net:443
pecl.php.net:80
phar.phpunit.de:443
planet.wordpress.org:443
playwright.azureedge.net:443
production.cloudflare.docker.com:443
registry-1.docker.io:443
registry.npmjs.org:443
repo.packagist.org:443
secure.gravatar.com:443
wordpress.org:443
- name: Checkout source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Generate self-contained package
run: |
git archive --format=tar --prefix=two-factor-provider-webauthn/ HEAD | (cd /var/tmp/ && tar xf -)
(cd /var/tmp/two-factor-provider-webauthn && composer install --no-dev --no-interaction && composer remove --update-no-dev --no-interaction composer/installers cweagans/composer-patches && rm -rf composer.lock composer.json patches vendor/madwizard/webauthn/.github vendor/madwizard/webauthn/conformance vendor/madwizard/webauthn/tests vendor/psr/log/Psr/Log/Test vendor/psr/http-message/docs vendor/typisttech)
- name: Patch docker-compose.yml
run: |
sed -i 's!- .:!- /var/tmp/two-factor-provider-webauthn:!' docker-compose.yml
- name: Set up Node.js environment
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0
with:
node-version: lts/*
cache: npm
- name: Install dependencies
run: npm ci
- name: Install Playwright
run: npx playwright install chromium
- name: Run Playwright E2E tests
run: npm run test:e2e
env:
WP_VERSION: php8.1
- name: Upload test results
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
if: failure()
with:
name: playwright-test-results-bundle
path: test-results/
retention-days: 3