Skip to content

try custom cypress action #10

try custom cypress action

try custom cypress action #10

Workflow file for this run

name: E2E Tests
on:
push:
branches:
- cypress-actions
jobs:
check-diffs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
cypress:
runs-on: ubuntu-latest
strategy:
matrix:
core:
- {name: 'WP trunk', version: 'WordPress/WordPress#master'}
- {name: 'WP minimum', version: 'WordPress/WordPress#6.4'}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set PHP version
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
coverage: none
tools: composer:v2
- name: Install PHP dependencies
run: composer i
- name: Setup node version and npm cache
uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
cache: 'npm'
- name: Install Node dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm ci --no-optional
- name: Set the core version and plugins config
run: ./tests/bin/set-core-version.js --core=${{ matrix.core.version }} --plugins=./${{ github.event.repository.name }}
- name: Log wp-env
run: cat .wp-env.override.json
- name: Set up WP environment
run: npm run env:start
- name: Test
run: npm run cypress:run