-
Notifications
You must be signed in to change notification settings - Fork 7
/
cypress.config.js
47 lines (34 loc) · 1.09 KB
/
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
39
40
41
42
43
44
45
46
47
const { defineConfig } = require("cypress");
const { isFileExist, findFiles } = require("cy-verify-downloads");
const fs = require("fs");
module.exports = defineConfig({
e2e: {
viewportHeight: 1080,
viewportWidth: 1920,
baseUrl: "http://localhost:3000",
// Every time a test runs, files (e.g. downloaded files from a download
// page test) from previous tests are deleted.
downloadsFolder: "cypress/downloads",
trashAssetsBeforeRuns: true,
setupNodeEvents(on, config) {
// Implement node event listeners here
// cy-verify-downloads plugin
on("task", {
async downloads(downloadsPath) {
return fs.readdirSync(downloadsPath);
},
findFiles,
isFileExist
});
},
experimentalStudio: true
},
component: {
viewportHeight: 1080,
viewportWidth: 1920,
devServer: {
bundler: "webpack",
framework: "nuxt"
}
}
});