Class CookieStore

java.lang.Object
com.codeborne.selenide.CookieStore
All Implemented Interfaces:
Conditional<CookieStore>

public class CookieStore extends Object implements Conditional<CookieStore>
  • Method Details

    • driver

      public Driver driver()
      Specified by:
      driver in interface Conditional<CookieStore>
      Returns:
      current Driver (used to take screenshots etc. in case of test failure)
    • object

      public CookieStore object()
      Specified by:
      object in interface Conditional<CookieStore>
      Returns:
      object under test
    • clear

      public void clear()
      Delete all the cookies for the current domain.
      See Also:
      • WebDriver.Options.deleteAllCookies()
    • delete

      public void delete(String name)
      Delete the named cookie from the current domain.
      See Also:
      • WebDriver.Options.deleteCookieNamed(String)
    • getAll

      public Set<org.openqa.selenium.Cookie> getAll()
      Get all the cookies for the current domain.
      See Also:
      • WebDriver.Options.getCookies()
    • get

      public @Nullable org.openqa.selenium.Cookie get(String name)
      Get cookie with given name for the current domain.
      See Also:
      • WebDriver.Options.getCookies()
    • add

      public void add(String name, String value)
    • add

      public void add(org.openqa.selenium.Cookie cookie)
    • size

      public int size()