Example usage for org.openqa.selenium.remote.service DriverService stop

List of usage examples for org.openqa.selenium.remote.service DriverService stop

Introduction

In this page you can find the example usage for org.openqa.selenium.remote.service DriverService stop.

Prototype

public void stop() 

Source Link

Document

Stops this service if it is currently running.

Usage

From source file:com.smash.revolance.ui.model.user.User.java

License:Open Source License

public void stopBot() throws Exception {
    if (isBrowserActive()) {
        WebDriver browser = getBrowser();
        if (browser != null) {
            browser.quit();//from  w w  w  .  j  a  v a2 s.c  om
        }

        DriverService driverService = getDriverService();
        if (driverService != null) {
            driverService.stop();
        }

        setBrowserActive(false);
    }
}