-
Notifications
You must be signed in to change notification settings - Fork 0
/
cypress.config.js
38 lines (37 loc) · 1018 Bytes
/
cypress.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
const dotenvFlowPlugin = require('cypress-dotenv-flow')
const { defineConfig } = require('cypress')
module.exports = defineConfig({
component: {
devServer: {
framework: 'next',
bundler: 'webpack',
},
},
e2e: {
baseUrl: 'http://localhost:3000',
chromeWebSecurity: false,
defaultCommandTimeout: 10000,
setupNodeEvents(on, config) {
config = dotenvFlowPlugin(config)
config.env = {
...process.env,
...config.env
}
return config
},
},
env: {
CYPRESS_SEARCH_QUERY: 'test',
NEXT_PUBLIC_PROVIDER_ID: process.env.NEXT_PUBLIC_PROVIDER_ID,
NEXT_PUBLIC_PROVIDER_NAME: process.env.NEXT_PUBLIC_PROVIDER_NAME,
NEXT_PUBLIC_TOKEN: process.env.NEXT_PUBLIC_TOKEN,
TEST_SCIENTIST_PW: '!test1234',
TEST_SCIENTIST_USER: '[email protected]',
TEST_SESSION_COOKIE: process.env.TEST_SESSION_COOKIE,
},
reporter: 'junit',
reporterOptions: {
mochaFile: 'cypress/results/results-[hash].xml',
toConsole: true,
},
})