Interface HasFederatedCredentialManagement

All Known Implementing Classes:
ChromeDriver, ChromiumDriver, EdgeDriver, FirefoxDriver, InternetExplorerDriver, RemoteWebDriver, SafariDriver

@Beta public interface HasFederatedCredentialManagement
Used by classes to indicate that they can interact with FedCM dialogs.
  • Method Details

    • setDelayEnabled

      void setDelayEnabled(boolean enabled)
      Disables the promise rejection delay.

      FedCM by default delays promise resolution in failure cases for privacy reasons (; this function allows turning it off to let tests run faster where this is not relevant.

    • resetCooldown

      void resetCooldown()
      Resets the FedCM dialog cooldown.

      If a user agent triggers a cooldown when the account chooser is dismissed, this function resets that cooldown so that the dialog can be triggered again immediately.

    • getFederatedCredentialManagementDialog

      FederatedCredentialManagementDialog getFederatedCredentialManagementDialog()
      Gets the currently open FedCM dialog, or null if there is no dialog.

      Can be used with WebDriverWait like: wait.until(driver -> ((HasFederatedCredentialManagement) driver). getFederatedCredentialManagementDialog() != null);