Skip to content

Instantly share code, notes, and snippets.

@atshane253
Created August 19, 2019 18:02
Show Gist options
  • Save atshane253/d9fb76ddc838a8e6f85e1db403918ae9 to your computer and use it in GitHub Desktop.
Save atshane253/d9fb76ddc838a8e6f85e1db403918ae9 to your computer and use it in GitHub Desktop.
Selenium WebDriver Wait for updatepanel postback
public static void WaitForUpdatePanel(this IWebDriver driver) =>
new WebDriverWait(driver, WAIT).Until(d=>
!(bool)(driver as IJavaScriptExecutor).ExecuteScript("return Sys.WebForms.PageRequestManager.getInstance().get_isInAsyncPostBack()"));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment