I have a feature file which has many scenarios.When i run, every time its initializing the new .Its performing every scenario in new .

I am using @before and @after

@Before

    public void statUp() throws IOException {
        KnowsTestContext.driver = utils.getDriver(reader.properties().getProperty("browser"));
    }

    @After

   public void tearDown(Scenario scenario) {
        KnowsTestContext.driver.quit();
        }

Is there any way to run all my scenarios on one browser?



Source link https://sqa.stackexchange.com/questions/34675/how-to---browser--instead-of--new-

LEAVE A REPLY

Please enter your comment!
Please enter your name here