Module: Selenium::WebDriver::DriverExtensions::HasFedCmDialog Private
Relationships & Source Files | |
Defined in: | rb/lib/selenium/webdriver/common/driver_extensions/has_fedcm_dialog.rb |
Instance Attribute Summary
-
#enable_fedcm_delay=(enable)
writeonly
Internal use only
Disables the promise rejection delay for FedCm.
Instance Method Summary
- #fedcm_dialog Internal use only
-
#reset_fedcm_cooldown
Internal use only
Resets the FedCm dialog cooldown.
- #wait_for_fedcm_dialog(timeout: 5, interval: 0.2, message: nil, ignore: nil) Internal use only
Instance Attribute Details
#enable_fedcm_delay=(enable) (writeonly)
Disables the promise rejection delay for FedCm.
FedCm by default delays promise resolution in failure cases for privacy reasons. This method allows turning it off to let tests run faster where this is not relevant.
# File 'rb/lib/selenium/webdriver/common/driver_extensions/has_fedcm_dialog.rb', line 28
def enable_fedcm_delay=(enable) @bridge.fedcm_delay(enable) end
Instance Method Details
#fedcm_dialog
[ GitHub ]#reset_fedcm_cooldown
Resets the FedCm dialog cooldown.
If a user agent triggers a cooldown when the account chooser is dismissed, this method resets that cooldown so that the dialog can be triggered again immediately.
# File 'rb/lib/selenium/webdriver/common/driver_extensions/has_fedcm_dialog.rb', line 36
def reset_fedcm_cooldown @bridge.reset_fedcm_cooldown end
#wait_for_fedcm_dialog(timeout: 5, interval: 0.2, message: nil, ignore: nil)
[ GitHub ]# File 'rb/lib/selenium/webdriver/common/driver_extensions/has_fedcm_dialog.rb', line 44
def wait_for_fedcm_dialog(timeout: 5, interval: 0.2, message: nil, ignore: nil) wait = Wait.new(timeout: timeout, interval: interval, message: , ignore: ignore) wait.until do fedcm_dialog if fedcm_dialog.type rescue Error::NoSuchAlertError nil end end