Select an option by visible text
Medium70 pts~25 min
- Select
- Dropdowns
Practice app · Workshop Registration
A registration form with text fields, radios, checkboxes, selects and validation.
Your starter code already declares TEST_URL — never hardcode a host.
Objective
Choose a country from a native select using its visible label.
Your task
- 1Open TEST_URL.
- 2Wrap
#countryin the Select helper (Select / SelectElement). - 3Select “India” by visible text.
- 4Assert the first selected option’s text is “India”.
Acceptance criteria
- The option is selected by visible text
#countryvalue is “in”- At least 1 assertion passes
Selenium WebDriver 4 · Selenium · Forms & inputs