-
Notifications
You must be signed in to change notification settings - Fork 0
/
cypress.config.ts
57 lines (38 loc) · 1.32 KB
/
cypress.config.ts
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import { defineConfig } from "cypress";
import path from 'path';
import tasks from './cypress/plugins/tasks';
import configE from 'dotenv';
/**
* Given undefined expected github secret,
* environment then assumed as local development
*/
if(process.env.CYPRESS_RECORD_KEY === undefined) {
configE.config();
}
const nodeEvents = (on: Cypress.PluginEvents, config: Cypress.ConfigOptions<any>) => {
// implement node event listeners here
config.projectId = process.env.CYPRESS_PROJECT_ID;
config.retries = 3;
on('task', tasks);
}
const config = defineConfig({
fixturesFolder: false,
video: true,
videoCompression: false,
setupNodeEvents: nodeEvents,
e2e: {
env: {
BASE_URL: 'https://ziping-liu-corporation.github.io/react-adobe-embed',
DEFAULT_PATH: "#/test",
DATEMODIFIED_CODE_DEPLOYED: process.env.DATEMODIFIED_CODE_DEPLOYED,
CYPRESS_BASE_URL: 'https://ziping-liu-corporation.github.io/react-adobe-embed',
},
"waitForAnimations": true,
video: true,
videoCompression: false,
projectId: process.env.CYPRESS_PROJECT_ID,
setupNodeEvents: nodeEvents,
supportFile: path.resolve(__dirname, 'cypress/support/commands.ts'),
},
});
export default config;