Viden Corporation Viden Corporation | Selenium WebDriver Training Environment Training Only | 📞 (855) 843-3601 | ✉ info@videncorporation.com
⚡ Explicit Wait — AJAX Load
Element appears after 2.5 seconds. Use WebDriverWait + expected_conditions.
Python:
WebDriverWait(driver, 10).until(
  EC.visibility_of_element_located((By.ID, "ajax-result"))
)
Waiting for request…
⏱ Countdown Timer
A button enables only when the countdown reaches 0. Practice visibility and enabled-state waits.
EC.element_to_be_clickable((By.ID, "timer-btn"))
5
📶 Progress Bar Load
Wait for progress bar to complete (width = 100%), then assert success text appears.
EC.text_to_be_present_in_element((By.ID, "progress-status"), "Complete")
👻 Skeleton → Real Content
Content loads after 2 seconds replacing skeleton placeholders. Assert by ID.
EC.presence_of_element_located((By.ID, "product-title-loaded"))
🪟 Windows & Tabs
Open new windows or tabs and switch between them using driver.window_handles.
Python:
original = driver.current_window_handle
driver.find_element(By.ID, "open-new-tab").click()
new_window = [w for w in driver.window_handles if w != original][0]
driver.switch_to.window(new_window)
Open New Tab Open New Window
📁 File Upload
Use send_keys() with an absolute file path on the hidden input. Then assert the filename appears.
driver.find_element(By.ID, "file-input").send_keys("/path/to/file.png")
📎 Click to choose a file or drag here
⌨️ Keyboard Events
Practice Keys class: ENTER, TAB, CONTROL+A, BACKSPACE and more.
from selenium.webdriver.common.keys import Keys
el.send_keys(Keys.CONTROL, 'a') # select all
el.send_keys(Keys.RETURN) # press enter
♾️ Load More (Pagination)
Click "Load More" to fetch new items. Practice scroll + dynamic list assertions.
driver.execute_script("arguments[0].scrollIntoView()", el)
WebDriverWait(driver, 5).until(EC.presence_of_element_located((By.ID, "item-7")))
🎧 Wireless Earbuds Pro — $79.99
⌚ Smart Watch X200 — $199.99
🔊 Bluetooth Speaker — $49.99