-
Notifications
You must be signed in to change notification settings - Fork 189
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
81 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// NOTE: this should really live in src/api/auth but jest-playwright doesn't | ||
// seen to know how to find it if I put it there. It has to be at the root. | ||
module.exports = { | ||
launchOptions: { | ||
headless: true, | ||
}, | ||
browsers: ['chromium', 'firefox', 'webkit'], | ||
serverOptions: { | ||
command: 'npx http-server src/api/auth/test/e2e -p 8888', | ||
port: 8888, | ||
launchTime: 10000, | ||
usedPortAction: 'kill', | ||
debug: true, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
const baseConfig = require('./jest.config.base'); | ||
|
||
module.exports = { | ||
...baseConfig, | ||
projects: ['<rootDir>/src/api/**/jest.config.e2e.js'], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,2 @@ | ||
// NOTE: you need to copy ../env.development to ../.env and run services | ||
const result = require('dotenv').config({ path: '../.env' }); | ||
|
||
if (result.error) { | ||
throw result.error; | ||
} | ||
|
||
const showServerLogs = false; | ||
|
||
module.exports = { | ||
launchOptions: { | ||
headless: true, | ||
}, | ||
browsers: ['chromium', 'firefox', 'webkit'], | ||
// Quit when any test fails to save time | ||
bail: 1, | ||
serverOptions: [ | ||
{ | ||
command: 'npx http-server test/e2e -p 8888', | ||
port: 8888, | ||
launchTime: 5000, | ||
usedPortAction: 'kill', | ||
debug: showServerLogs, | ||
}, | ||
], | ||
}; | ||
// Due to https://github.com/playwright-community/jest-playwright/issues/446 | ||
// we put our jest-playwright config in the Telescope root, see ./jest-playwright.confing.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,12 @@ | ||
const baseConfig = require('../../../jest.config.base'); | ||
|
||
module.exports = { | ||
...baseConfig, | ||
rootDir: '../../..', | ||
setupFiles: ['<rootDir>/jest.setup.js', '<rootDir>/src/api/auth/jest.setup.js'], | ||
testMatch: ['<rootDir>/src/api/auth/test/e2e/**/*.test.js'], | ||
collectCoverageFrom: ['<rootDir>/src/api/auth/server.js', '<rootDir>/src/api/auth/src/**/*.js'], | ||
// We use jest-playwright to do browser tests, https://github.com/playwright-community/jest-playwright | ||
// See the jest-playwright config in the Telescope root ./jest-playwright.config.js | ||
preset: 'jest-playwright-preset', | ||
testPathIgnorePatterns: ['/node_modules/'], | ||
testMatch: ['<rootDir>/test/e2e/**/*.test.js'], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.