Selenium Automation: Dynamic Dropdown Selection This is a simple Selenium automation script that demonstrates how to interact with a dynamic dropdown on a web page using Python. The script selects a country (e.g., Canada) from the dropdown by typing a partial name and clicking the appropriate option.
Features: Automates interaction with a dynamic dropdown menu. Uses Selenium to locate elements by ID, CSS selectors, and attributes. Demonstrates real-world automation skills, such as typing input, selecting from dropdowns, and validating results.
What the Script Does: Launches Chrome and navigates to Rahul Shetty Academy's dropdown practice page. Maximizes the browser window for better visibility. Inputs the partial name "Can" into the text box, triggering the dropdown options. Searches through the dropdown for "Canada" and clicks on it. Verifies that the selected value is correctly updated in the dropdown input box. Closes the browser after a brief delay.
Learning Objectives: This project is part of my portfolio as I learn automation with Selenium in Python. Through this script, I have practiced:
Locating elements using Selenium locators (ID, CSS, etc.). Handling dynamic dropdowns. Writing clean, maintainable Python code. Validating web element interactions using assertions.
Limitations: This script is specific to the dropdown functionality on the Rahul Shetty Academy website. It assumes that the website's structure (e.g., element IDs, classes) does not change.
This is for Educational purposes only