Skip to content

Fix/storie and bugs #10

Fix/storie and bugs

Fix/storie and bugs #10

name: Cypress E2E Tests
on:
pull_request:
types: [opened, synchronize, ready_for_review]
workflow_dispatch:
jobs:
cypress_e2e_tests:
name: Cypress End 2 End Tests
runs-on: ubuntu-latest
if: ${{ github.repository == 'publisherwp/publisher-core' || github.event_name == 'pull_request' }}
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Setup SSH
uses: MrSquaare/ssh-setup-action@v1
with:
host: github.com
private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Clone Submodule
run: |
cd libs
git clone [email protected]:publisherwp/storybook.git
- name: Setup Node.js and install dependencies
uses: ./.github/setup-node
- name: Install Composer Packages
run: composer install
- name: Build wp-env app
run: npm run build:wp-env-app
- name: Start WordPress Environment
run: |
npm run env:start
npm run plugin:activate
- name: Wait for WordPress to Start
run: sleep 40
- name: Run Cypress E2E Tests
run: npm run test:e2e
- name: Stop WordPress Environment
run: npm run env:stop