Skip to content

chore(deps): lock file maintenance #1593

chore(deps): lock file maintenance

chore(deps): lock file maintenance #1593

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: read
jobs:
e2e:
name: "Run E2E tests (use wordpress:${{ matrix.wordpress }} image)"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
wordpress:
- php7.4
- php8.0
- php8.1
- beta-php7.4
- beta-php8.0
- beta-php8.1
steps:
- name: Checkout source code
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
- name: Set up Node.js environment
uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1
with:
node-version: lts/*
cache: npm
- name: Install dependencies
run: npm ci
- name: Set up PHP
uses: shivammathur/setup-php@72ae4ccbe57f82bbe08411e84e2130bd4ba1c10f # 2.25.5
- name: Install Composer Dependencies
uses: ramsey/composer-install@83af392bf5f031813d25e6fe4cd626cdba9a2df6 # 2.2.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@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
if: failure()
with:
name: playwright-test-results
path: test-results/
retention-days: 3
e2e-bundle:
name: Run E2E tests on the generated plugin
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0
- 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@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1
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.0
- name: Upload test results
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
if: failure()
with:
name: playwright-test-results
path: test-results/
retention-days: 3