0

I have 2 scenarios (Codeceptjs and I am using webdriverIO helper) at the moment. After running the 1st scenario the browser closes. A new browser opens for the 2nd scenario. Using pause() did not solve the problem because after the pause the 1st browser still closed.

This is the skeleton:

Feature('some feature');

let url = "*some url*";

Scenario('Login with wrong credentials', (I) => {
  I.amOnPage(url);
  I.seeInCurrentUrl("*some part of the url*");

  ...

});

Scenario('Login with correct credentials', (I) => {

  I.seeInCurrentUrl("*some part of the url*");

  ...

});

Any suggestions? I want to run all scenarios in 1 browser.

Thanks!

1 Answers1

0

Found the solution to be restart:false which I added in the codecept.conf.js file

helpers: { WebDriver: { url: '...', browser: 'chrome', restart: false }, ...