Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Four Tips for More Testable UI
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Jim Holmes
March 17, 2019
Technology
0
52
Four Tips for More Testable UI
Quick talk given at the 2019 Microsoft MVP summit during the ALM group's MVP2MVP sessions.
Jim Holmes
March 17, 2019
Tweet
Share
More Decks by Jim Holmes
See All by Jim Holmes
Adapting to Change in Software Delivery
jimholmes
0
78
Public_Speaking.pdf
jimholmes
0
120
Trusted System Boundaries
jimholmes
0
96
What's Worse? Zombies or Brittle UI Tests?
jimholmes
0
120
Odd Parallels Between Weightlifting and Software Delivery
jimholmes
0
61
Is Quality The Bottleneck?
jimholmes
0
130
Don't Fear Leadership
jimholmes
0
99
Intro To TDD
jimholmes
1
85
Honor Flight #20 (Bay Area) Recap
jimholmes
0
130
Other Decks in Technology
See All in Technology
Amazon S3 Vectorsを使って資格勉強用AIエージェントを構築してみた
usanchuu
3
450
制約が導く迷わない設計 〜 信頼性と運用性を両立するマイナンバー管理システムの実践 〜
bwkw
3
920
小さく始めるBCP ― 多プロダクト環境で始める最初の一歩
kekke_n
1
380
10Xにおける品質保証活動の全体像と改善 #no_more_wait_for_test
nihonbuson
PRO
2
230
顧客の言葉を、そのまま信じない勇気
yamatai1212
1
350
Amazon Bedrock Knowledge Basesチャンキング解説!
aoinoguchi
0
130
会社紹介資料 / Sansan Company Profile
sansan33
PRO
15
400k
2026年、サーバーレスの現在地 -「制約と戦う技術」から「当たり前の実行基盤」へ- /serverless2026
slsops
2
220
GitLab Duo Agent Platform × AGENTS.md で実現するSpec-Driven Development / GitLab Duo Agent Platform × AGENTS.md
n11sh1
0
130
プロポーザルに込める段取り八分
shoheimitani
1
190
データの整合性を保ちたいだけなんだ
shoheimitani
8
3.1k
Claude_CodeでSEOを最適化する_AI_Ops_Community_Vol.2__マーケティングx_AIはここまで進化した.pdf
riku_423
2
530
Featured
See All Featured
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
Side Projects
sachag
455
43k
Fashionably flexible responsive web design (full day workshop)
malarkey
408
66k
Embracing the Ebb and Flow
colly
88
5k
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
98
Google's AI Overviews - The New Search
badams
0
900
Designing for Timeless Needs
cassininazir
0
130
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
170
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
5.8k
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
1
49
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.2k
Transcript
Testable UIs
Or: How to help your test automation folks drink less
[email protected]
@aJimHolmes
Fortune 10 client Java 6 Enterprise-ready components HP build and
SCM tools “What’s a unit test?”
Thank you ET
Generalized Talk Ideas apply to all UI and automation tools
https://github.com/jimholmes/ Demo-Site
Two main problems in all UI testing
Finding Stuff
Async
Also SharePoint
Finding stuff == Locators
For Web, prefer: IDs CSS/JQuery-ish Name Custom Attributes
As a last resort: XPath
None
Create Good Locators
0) Own Your HTML
None
None
None
FindElement.ById(“grid”)
None
None
1) Understand your controls / frameworks
None
None
None
FindElement.ByCss( “some big stupid CSS string”)
Someone changes style
None
None
None
FindElement.ById( “update-btn”)
2) Tweak dynamic data
None
Find elements by text content. Might not be granular enough.
None
None
No useful attributes
None
None
None
ID is position-based. Data changes, IDs change.
None
We own the code!
Is there some useful data in your objects?
None
None
None
None
None
FindElement.ById( contains(“Cobb”) )
“Name” isn’t all that useful. Got contract numbers? Project IDs?
Other stuff? Find good metadata!
3) Make complex async less painful
None
SharePoint
wait until expected condition 1 wait until expected condition 2
IF SOMETHING wait until expected condition 3 IF SOMETHING ELSE wait until expected condition 4 FINALLY wait until expected condition 342
We own the code!
Create “flags” when async is complete
None
None
None
None
None
Wait until flags.div(responseType=create) exists
0) Add static IDs 1) Tweak controls 2) Use data
for locators 3) Build flags/latches for complex async
None
https://github.com/jimholmes/ Demo-Site