Class WebDriverWrapper

All Implemented Interfaces:

@ParametersAreNonnullByDefault public class WebDriverWrapper extends Object implements Driver
A `Driver` implementation which uses given webdriver [and proxy]. It doesn't open a new browser. It doesn't start a new proxy.
  • Constructor Details

  • Method Details

    • config

      @CheckReturnValue @Nonnull public Config config()
      Specified by:
      config in interface Driver
    • browser

      @CheckReturnValue @Nonnull public Browser browser()
      Specified by:
      browser in interface Driver
    • hasWebDriverStarted

      @CheckReturnValue public boolean hasWebDriverStarted()
      Specified by:
      hasWebDriverStarted in interface Driver
    • getWebDriver

      @CheckReturnValue @Nonnull public org.openqa.selenium.WebDriver getWebDriver()
      Specified by:
      getWebDriver in interface Driver
    • getProxy

      @CheckReturnValue @Nonnull public SelenideProxyServer getProxy()
      Specified by:
      getProxy in interface Driver
    • getAndCheckWebDriver

      @CheckReturnValue @Nonnull public org.openqa.selenium.WebDriver getAndCheckWebDriver()
      Specified by:
      getAndCheckWebDriver in interface Driver
    • browserDownloadsFolder

      @CheckReturnValue @Nullable public DownloadsFolder browserDownloadsFolder()
      Specified by:
      browserDownloadsFolder in interface Driver
    • close

      public void close()
      Close the webdriver.

      NB! The behaviour was changed in Selenide 5.4.0 Even if webdriver was created by user - it will be closed. It may hurt if you try to use this browser after closing.

      Specified by:
      close in interface Driver