Protractor : Refreshing browser instance between testsuites

1.3k Views Asked by At

I am running multiple test suits in series and hence the same browser object of protractor is getting used in all test suites. Is there a way in protractor to flush the state of this browser object after each test suite is finished i.e. making the browser object stateless across the testsuites.

1

There are 1 best solutions below

0
On BEST ANSWER

Maybe this capability can help: restartBrowserBetweenTests

Example:

 capabilities: {
'browserName': 'chrome',
  'chromeOptions': {
'args': ['profile.default_content_settings.popups:1'] }
},

restartBrowserBetweenTests: true,

plugins: [{
package: 'protractor-console',
logLevels: ['info']
}],

baseUrl: 'http://localhost:3000'

}