Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Four Tips for More Testable UI
Search
Jim Holmes
March 17, 2019
Technology
75
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
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
120
Public_Speaking.pdf
jimholmes
0
150
Trusted System Boundaries
jimholmes
0
150
What's Worse? Zombies or Brittle UI Tests?
jimholmes
0
180
Odd Parallels Between Weightlifting and Software Delivery
jimholmes
0
90
Is Quality The Bottleneck?
jimholmes
0
160
Don't Fear Leadership
jimholmes
0
140
Intro To TDD
jimholmes
1
120
Honor Flight #20 (Bay Area) Recap
jimholmes
0
170
Other Decks in Technology
See All in Technology
AI時代のPRレビューにどう向き合うか?
kairim0
1
220
Loop Engineering これくらいでいい
mikanichinose
0
230
全PRの83%が AIレビューだけでマージできるようになった開発組織は その後どうなったか @2026/10
athug
0
140
AI時代だからこそ推したい!Gitコマンド再入門
munakata
0
180
AI 時代の Azure エンジニアリング ~ 私たちは何を磨き、何を任せるのか ~
chack411
1
610
サブエージェントと Claude Mods で作る独自 Advisor ツールの話
kenichiodo
1
120
PagerDuty Tech Hub-鳴らすけれど、人は動かない
ezaki
0
120
初対面のメンバーがチームを組み、Claude Codeでゼロからサービスをリリース
mkdev10
1
120
M5Stackで作る BLEマウス GPSログの世界
tomokusaba
0
200
AIは「聞けば答える」から「任せると自分で進める」へ - JACTIMペナン地域部会・ペナン三水会講演
knishioka
0
110
宣言型部分更新は何を解決しどこへ向かうのか
shuta13
1
360
Getting Started with Google Antigravity
glaforge
0
240
Featured
See All Featured
Music & Morning Musume
bryan
48
7.4k
The Invisible Side of Design
smashingmag
301
52k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
4
1.2k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
300
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
630
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
530
HTML-Aware ERB: The Path to Reactive Rendering @ RubyCon 2026, Rimini, Italy
marcoroth
5
810
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
730
So, you think you're a good person
axbom
PRO
2
2.2k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6.1k
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