fix: open browser at correct time during lifecycle (#19572)

This commit is contained in:
Tim Griesser
2022-01-12 13:41:25 -05:00
committed by GitHub
parent 139d88d91f
commit bfc032a2d4
32 changed files with 285 additions and 289 deletions
@@ -4,16 +4,8 @@ module.exports = {
'viewportWidth': 500,
'viewportHeight': 800,
'component': {
setupNodeEvents (on, config) {
// load file devServer that comes with this plugin
// https://github.com/bahmutov/cypress-react-unit-test#install
const devServer = require('@cypress/react/plugins/react-scripts')
devServer(on, config)
// IMPORTANT to return the config object
// with the any changed environment variables
return config
},
// load file devServer that comes with this plugin
// https://github.com/bahmutov/cypress-react-unit-test#install
devServer: require('@cypress/react/plugins/react-scripts'),
},
}