Skip to content

Commit

Permalink
refactor(e2e): update setup
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelmartineau committed Apr 1, 2024
1 parent eec6edb commit 766d843
Show file tree
Hide file tree
Showing 11 changed files with 2,517 additions and 1,269 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,24 @@ jobs:
e2e:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Install NPM dependencies
run: npm install

- name: Install reverse proxy for dev
run: npm run proxy

# Runs a single command using the runners shell
- name: Run the app
run: npm run start:e2e

- name: Cypress run
uses: cypress-io/github-action@v1
uses: cypress-io/github-action@v6
with:
working-directory: e2e
server-tests:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Install NPM dependencies
run: npm install
Expand All @@ -42,7 +39,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Install NPM dependencies
run: npm install
Expand All @@ -53,7 +50,7 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Install NPM dependencies
run: npm install
Expand Down
10 changes: 10 additions & 0 deletions e2e/cypress.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
const { defineConfig } = require('cypress');

module.exports = defineConfig({
e2e: {
baseUrl: 'http://localhost:3000',
setupNodeEvents() {
// implement node event listeners here
},
},
});
1 change: 0 additions & 1 deletion e2e/cypress.json

This file was deleted.

File renamed without changes.
File renamed without changes.
20 changes: 20 additions & 0 deletions e2e/cypress/support/e2e.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// ***********************************************************
// This example support/e2e.js is processed and
// loaded automatically before your test files.
//
// This is a great place to put global configuration and
// behavior that modifies Cypress.
//
// You can change the location of this file or turn off
// automatically serving support files with the
// 'supportFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/configuration
// ***********************************************************

// Import commands.js using ES2015 syntax:
import './commands';

// Alternatively you can use CommonJS syntax:
// require('./commands')
Loading

0 comments on commit 766d843

Please sign in to comment.