MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / accept

Method accept

py/selenium/webdriver/common/alert.py:64–70  ·  view source on GitHub ↗

Accepts the alert available. Example: Alert(driver).accept() # Confirm a alert dialog.

(self)

Source from the content-addressed store, hash-verified

62 self.driver.execute(Command.W3C_DISMISS_ALERT)
63
64 def accept(self) -> None:
65 """Accepts the alert available.
66
67 Example:
68 Alert(driver).accept() # Confirm a alert dialog.
69 """
70 self.driver.execute(Command.W3C_ACCEPT_ALERT)
71
72 def send_keys(self, keysToSend: str) -> None:
73 """Send Keys to the Alert.

Callers

nothing calls this directly

Calls 1

executeMethod · 0.65

Tested by

no test coverage detected