forked from cypress-io/github-action
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcypress.config.js
More file actions
31 lines (27 loc) · 803 Bytes
/
cypress.config.js
File metadata and controls
31 lines (27 loc) · 803 Bytes
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
import { defineConfig } from 'cypress'
import os from 'node:os'
export default defineConfig({
fixturesFolder: false,
e2e: {
setupNodeEvents (on) {
on('before:browser:launch', (browser, launchOptions) => {
console.log('before launching browser')
console.log(browser)
if (browser.name === 'chrome') {
// https://www.ghacks.net/2013/10/06/list-useful-google-chrome-command-line-switches/
launchOptions.args.push('--window-size=1920,1080')
console.log('chrome launch args:')
console.log(launchOptions.args.join(os.EOL))
return launchOptions
}
})
on('task', {
log (message) {
console.log(message)
return null
},
})
},
supportFile: false,
},
})