Member-only story
Drive Google Map Address validation with Selenium WebDriver
How to use Selenium WebDriver to select and validate a Google Map address
3 min readMar 19, 2023
A repost of my daughter’s article, I added a few notes. This is also included in my “How to in Selenium WebDriver” series.
Integrating Google Maps to validate an address is a common feature on web pages. This article shows how to automate that in raw Selenium WebDriver.
Table of Contents:
· Test Design
∘ Execution (Video)
· Test Script:
∘ Refinement
∘ Refactoring
· Zhimin’s Notes
Test Design:
Quite straightforward.
- Find the address text field element, and clear it first.
In case it was not empty. - Typing in the new address to the element.
Don’t need to be the full address, as Google maps will try to auto-complete it. - Send
down
keys (to the same element) repeatedly until the desired entry is highlighted.
Add a minor…