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
Jim Holmes
March 17, 2019
Technology
58
0
Share
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
More Decks by Jim Holmes
See All by Jim Holmes
Adapting to Change in Software Delivery
jimholmes
0
99
Public_Speaking.pdf
jimholmes
0
130
Trusted System Boundaries
jimholmes
0
120
What's Worse? Zombies or Brittle UI Tests?
jimholmes
0
150
Odd Parallels Between Weightlifting and Software Delivery
jimholmes
0
69
Is Quality The Bottleneck?
jimholmes
0
150
Don't Fear Leadership
jimholmes
0
110
Intro To TDD
jimholmes
1
100
Honor Flight #20 (Bay Area) Recap
jimholmes
0
150
Other Decks in Technology
See All in Technology
LookerとADKで作る社内AIエージェント
chanyou0311
0
260
20260513_生成AIを専属DSに_AI分析結果の検品テクニック_ハンズオン_交通事故データ
doradora09
PRO
0
230
Oracle AI Database@Azure:サービス概要のご紹介
oracle4engineer
PRO
6
1.7k
エムスリーテクノロジーズ株式会社 エンジニア向け紹介資料 / M3 Technologies Company Deck
m3_engineering
0
190
Oracle AI Database@AWS:サービス概要のご紹介
oracle4engineer
PRO
4
2.6k
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
4.5k
SLI/SLO、「完全に理解した」から「チョットデキル」へ
maruloop
5
560
写真で見るAWS Summit Singapore 2026
k_adachi_01
0
110
エンタープライズの厳格な制約を開発者に意識させない:クラウドネイティブ開発基盤設計/cloudnative-kaigi-golden-path
mhrtech
0
450
CARTA HOLDINGS エンジニア向け 採用ピッチ資料 / CARTA-GUIDE-for-Engineers
carta_engineering
0
47k
Claude Code / Codex / Kiro に AWS 権限を 渡すとき、何を設計すべきか
k_adachi_01
5
1.7k
【関西製造業祭り2026春】現場を変える技術はここまで来た〜世界最大の製造業見本市から持って帰ってきたもの〜
tanakaseiya
0
180
Featured
See All Featured
Facilitating Awesome Meetings
lara
57
6.8k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
62
54k
What does AI have to do with Human Rights?
axbom
PRO
1
2.1k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
560
Believing is Seeing
oripsolob
1
120
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
65
55k
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
150
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
1
52
Are puppies a ranking factor?
jonoalderson
1
3.4k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
340
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