exports.config = { // add other options here as normal capabilities: [ { browserName: 'chrome'}, ], // This is the important part!!! onPrepare: () => { if ( this.config.chromeDriver ) require('./chromedriver').start(this.config); }, after: () => { if ( this.config.chromeDriver ) require('./chromedriver').stop(); }, // custom option: chromeDriver: true, };