Class PlaywrightDriver
- java.lang.Object
-
- com.intuit.karate.driver.playwright.PlaywrightDriver
-
-
Field Summary
Fields Modifier and Type Field Description protected intcurrentMouseXposprotected intcurrentMouseYposstatic StringDRIVER_TYPE-
Fields inherited from interface com.intuit.karate.driver.Driver
METHOD_NAMES
-
-
Constructor Summary
Constructors Constructor Description PlaywrightDriver(DriverOptions options, Command command, String webSocketUrl)
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.intuit.karate.driver.Driver
above, afterScenario, below, delay, exists, highlight, highlight, highlightAll, highlightAll, input, input, input, keys, leftOf, locate, locateAll, locateAll, methodNames, mouse, mouse, mouse, near, onFailure, optional, retry, retry, retry, rightOf, screenshot, screenshot, script, scriptAll, scriptAll, scroll, setCookies, waitFor, waitForAny, waitForAny, waitForEnabled, waitForResultCount, waitForResultCount, waitForText, waitForUrl, waitUntil, waitUntil
-
Methods inherited from interface com.intuit.karate.core.Plugin
getRuntime
-
-
-
-
Field Detail
-
DRIVER_TYPE
public static final String DRIVER_TYPE
- See Also:
- Constant Field Values
-
currentMouseXpos
protected int currentMouseXpos
-
currentMouseYpos
protected int currentMouseYpos
-
-
Constructor Detail
-
PlaywrightDriver
public PlaywrightDriver(DriverOptions options, Command command, String webSocketUrl)
-
-
Method Detail
-
unlockAndProceed
protected void unlockAndProceed()
-
nextId
public int nextId()
-
waitSync
public void waitSync()
-
start
public static PlaywrightDriver start(Map<String,Object> map, ScenarioRuntime sr)
-
send
public void send(PlaywrightMessage pwm)
-
receive
public void receive(PlaywrightMessage pwm)
-
sendAndWait
public PlaywrightMessage sendAndWait(PlaywrightMessage pwm, java.util.function.Predicate<PlaywrightMessage> condition)
-
getOptions
public DriverOptions getOptions()
- Specified by:
getOptionsin interfaceDriver
-
elementIds
public List<String> elementIds(String locator)
- Specified by:
elementIdsin interfaceDriver
-
fullscreen
public void fullscreen()
- Specified by:
fullscreenin interfaceDriver
-
setDimensions
public void setDimensions(Map<String,Object> map)
- Specified by:
setDimensionsin interfaceDriver
-
switchPage
public void switchPage(String titleOrUrl)
- Specified by:
switchPagein interfaceDriver
-
switchPage
public void switchPage(int index)
- Specified by:
switchPagein interfaceDriver
-
switchFrame
public void switchFrame(int index)
- Specified by:
switchFramein interfaceDriver
-
switchFrame
public void switchFrame(String locator)
- Specified by:
switchFramein interfaceDriver
-
getDimensions
public Map<String,Object> getDimensions()
- Specified by:
getDimensionsin interfaceDriver
-
getDialogText
public String getDialogText()
- Specified by:
getDialogTextin interfaceDriver
-
screenshot
public byte[] screenshot(boolean embed)
- Specified by:
screenshotin interfaceDriver
-
deleteCookie
public void deleteCookie(String name)
- Specified by:
deleteCookiein interfaceDriver
-
clearCookies
public void clearCookies()
- Specified by:
clearCookiesin interfaceDriver
-
getCookies
public List<Map> getCookies()
- Specified by:
getCookiesin interfaceDriver
-
screenshot
public byte[] screenshot(String locator, boolean embed)
- Specified by:
screenshotin interfaceDriver
-
isTerminated
public boolean isTerminated()
- Specified by:
isTerminatedin interfaceDriver
-
-