SlideShare a Scribd company logo
@giltayar
Creating a Flawless User Experience,
End-To-End, Functional to Visual
Gil Tayar (@giltayar)
April 2019
Github repo: https://github.com/applitools/cypress-applitools-webinar
This presentation: http://bit.ly/cypress-applitools-webinar
Gleb’s presentation: https://slides.com/bahmutov/flawless-tests
1
@giltayar
2
VP of Engineering, Cypress.io
Senior Architect, Applitools
@giltayar
Why Do We Write
Tests?
3
@giltayar
Answer: To Remove Fear
4
@giltayar
Fear of Adding Code
5
@giltayar
Fear of Removing Code
6
@giltayar
Fear of Refactoring
7
7
@giltayar
Functional Testing Solve That
● I add/remove/refactor, run the tests, and voila!
● Fearless
8
@giltayar
And Cypress is the perfect tool for that!
9
@giltayar
(although I will let Gleb expound on that)
10
@giltayar
Except for one teeny tiny area of my code
11
@giltayar
HTML and CSS Markup
When I change my HTML and CSS,
do the pages still look like they should?
● Yes, the checkbox is disabled. But does it look disabled?
● In my todo row, when it’s completed, does it look striked out?
● Does the whole page look OK?
● After I create a new row, does it still look OK?
12
@giltayar
Visual testing enables you to…
● Add markup
● Remove markup
● Refactor markup
Without Fear
13
@giltayar
And Applitools Eyes is the perfect tool for that!
14
@giltayar
Functional and Visual Tests enable you to
cover your application cover to cover
15
@giltayar
Cypress Functional Testing
16
@giltayar
Take it, Gleb!
17
@giltayar
Applitools Visual Testing
18
@giltayar
How does one go about visually testing an app?
● Automate the browser, do what the user would:
○ Use Cypress!
● For each page you would like to visually test:
○ Navigate/click/type to it
○ Take a screenshot
○ Check that it’s OK
19
@giltayar
How would it look like?
it('logs in', () => {
cy.contains('a.nav-link', 'Sign in').click()
cy.eyesCheckWindow ('Login page')
const user = Cypress.env('user')
cy.get('input[type="email"]' ).type(user.email)
cy.get('input[type="password"]' ).type(user.password)
cy.get('button[type="submit"]' ).click()
cy.eyesCheckWindow ('Empty home page after login' )
})
20
@giltayar
How would it look like?
it('logs in', () => {
cy.contains('a.nav-link', 'Sign in').click()
cy.eyesCheckWindow ('Login page')
const user = Cypress.env('user')
cy.get('input[type="email"]').type(user.email)
cy.get('input[type="password"]').type(user.password)
cy.get('button[type="submit"]').click()
cy.eyesCheckWindow ('Empty home page after login' )
})
21
Actions
@giltayar
How would it look like?
it('logs in', () => {
cy.contains('a.nav-link', 'Sign in').click()
cy.eyesCheckWindow('Login page')
const user = Cypress.env('user')
cy.get('input[type="email"]' ).type(user.email)
cy.get('input[type="password"]' ).type(user.password)
cy.get('button[type="submit"]' ).click()
cy.eyesCheckWindow('Empty home page after login')
})
22
Screenshots
@giltayar
This is how test code looks like
Navigate
Click, type, click
checkScreenshot
Click, click, type
checkScreenshot
Type, click, click
checkScreenshot
Click, click, click
checkScreenshot
23
@giltayar
How do we check that the screenshot is OK?
You send us screenshots of your app
We compare the screenshots with baseline images
We report any differences found
You accept or reject the differences
@giltayar
Simple, Right?
25
@giltayar
Building a UI
that you use to accept or reject a difference
26
@giltayar
27
@giltayar
28
@giltayar
29
@giltayar
A Huge Difficulty: False Positives
30
@giltayar
@giltayar
@giltayar
@giltayar
But also what about…?
● Different browsers
○ Chrome, Firefox, Safari
● Different responsive widths and pixel densities
○ Smartphone width and pixel density
○ Tablet width
○ Regular desktop width
○ Retina display width and pixel density
34
@giltayar
So...
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
1024
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
2500
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
1024
…
35
@giltayar
Run each test ten times?
36
@giltayar
Run each test ten times?
(not even with Cypress…)
37
@giltayar
Why is this not a problem in functional e2e tests?
Because browsers have converged functionally
38
@giltayar
How do we solve this problem?
We parallelize
39
@giltayar
Solution: Parallelizing the tests
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
1024
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
1024
Navigate
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
Click, click, click
checkScreenshot
2500
40
@giltayar
There’s a better solution
41
@giltayar
Parallelize the screenshots!
Navigate
Click, click, click
checkScreenshot #1
Click, click, click
checkScreenshot #2
Click, click, click
checkScreenshot #3
Click, click, click
checkScreenshot #4
...768 ,1024,2500
...768 ,1024,2500
...768 ,1024,2500
...768 ,1024,2500
screen #1 @
768
screen #1 @
1024
screen #1 @
2500
screen #2 @ 768
screen #1 @ 768
screen #1 @
1024
screen #1 @
2500
screen
#2
@
768
42
@giltayar
How? DOM Snapshots!
Navigate
Click, click, click
checkScreenshot #1
Click, click, click
checkScreenshot #2
Click, click, click
checkScreenshot #3
Click, click, click
checkScreenshot #4
screen #1 @
768
screen #1 @
1024
screen #1 @
2500
screen #1 @ 768
screen #1 @
1024
screen #1 @
2500
DOM Snapshot #1
Screenshots!43
@giltayar
How? DOM Snapshots!
Navigate
Click, click, click
checkScreenshot #1
Click, click, click
checkScreenshot #2
Click, click, click
checkScreenshot #3
Click, click, click
checkScreenshot #4
screen #1 @
768
screen #1 @
1024
screen #1 @
2500
screen #1 @ 768
screen #1 @
1024
screen #1 @
2500
DOM Snapshot #1
Screenshots!44
@giltayar
The Applitools
Visual Grid
DOM Snapshot
Screenshots
Applitools
Eyes Server
45
@giltayar
OK, OK. But how?
How do I write
tests?
Show me some
code!
46
@giltayar
Things we haven’t shown
● Take selective screenshot using selector
● Github and Bitbucket integration
● JIRA integration
● Shadow DOM and Canvas support: coming soon
● Ignore regions, floating ignore regions
● Layout mode!
47
@giltayar
Coming Soon
● A Cypress course in TestAutomationU
○ https://testautomationu.applitools.com/
○ Written by yours truly
48
@giltayar
Thank You
Github repo: https://github.com/applitools/cypress-applitools-webinar
This presentation: http://bit.ly/cypress-applitools-webinar
Gleb’s presentation: https://slides.com/bahmutov/flawless-tests
49
@giltayar
Question
50

More Related Content

PDF
como era... patroa
PDF
Interview with Philippe Borremans 2009
PDF
ข้อสอบเมทริกซ์
PDF
เฉลยข้อสอบเมทริกซ์ ตอนที่ 1
PDF
Guia rapida de configuracion flejera pd42 (2)
PDF
เฉลยข้อสอบเมทริกซ์ ตอนที่ 2
PDF
Filtrowanie treści - dylematy operatorów serwisów społecznościowych
PDF
[Waterworks] City Presentation - Rosenheim(Germany)
como era... patroa
Interview with Philippe Borremans 2009
ข้อสอบเมทริกซ์
เฉลยข้อสอบเมทริกซ์ ตอนที่ 1
Guia rapida de configuracion flejera pd42 (2)
เฉลยข้อสอบเมทริกซ์ ตอนที่ 2
Filtrowanie treści - dylematy operatorów serwisów społecznościowych
[Waterworks] City Presentation - Rosenheim(Germany)

Similar to Creating a flawless user experience, end to-end, functional to visual - Slides by Gil Tayar (20)

PDF
Visual Regression Testing at the Speed of Unit Testing -- by Gil Tayar
PPTX
Visual Testing: The Missing Piece of the Puzzle -- presentation by Gil Tayar
PDF
Visual Testing: Turbo-Charge Your Functional Tests with Visual Powers in Just...
PDF
Advanced iOS
PDF
Going web native
PDF
"Impact of front-end architecture on development cost", Viktor Turskyi
PDF
Lipstick on a Magical Pony: dynamic web pages without Javascript
PPTX
Practical Secure Coding Workshop - {DECIPHER} Hackathon
PDF
BDD - Writing better scenario
PPTX
Cultural learnings of testing for make benefit glorious nation of startup
PDF
How not to suck at Cyber Security
ODP
WordPress Accessibility: WordCamp Chicago
PDF
Ultimate Free Digital Marketing Toolkit #EdgeBristol 2012
PDF
QSDA2022: Qlik Sense Data Architect | Q & A
PDF
«iPython & Jupyter: 4 fun & profit», Лев Тонких, Rambler&Co
PDF
Collaborating with Developers: How-to Guide for Test Engineers - By Gil Tayar
PDF
The State of Front-end At CrowdTwist
PDF
Metrics-Driven Engineering
PDF
Cypress vs Selenium WebDriver: Better, Or Just Different? -- by Gil Tayar
PDF
Software Testing
Visual Regression Testing at the Speed of Unit Testing -- by Gil Tayar
Visual Testing: The Missing Piece of the Puzzle -- presentation by Gil Tayar
Visual Testing: Turbo-Charge Your Functional Tests with Visual Powers in Just...
Advanced iOS
Going web native
"Impact of front-end architecture on development cost", Viktor Turskyi
Lipstick on a Magical Pony: dynamic web pages without Javascript
Practical Secure Coding Workshop - {DECIPHER} Hackathon
BDD - Writing better scenario
Cultural learnings of testing for make benefit glorious nation of startup
How not to suck at Cyber Security
WordPress Accessibility: WordCamp Chicago
Ultimate Free Digital Marketing Toolkit #EdgeBristol 2012
QSDA2022: Qlik Sense Data Architect | Q & A
«iPython & Jupyter: 4 fun & profit», Лев Тонких, Rambler&Co
Collaborating with Developers: How-to Guide for Test Engineers - By Gil Tayar
The State of Front-end At CrowdTwist
Metrics-Driven Engineering
Cypress vs Selenium WebDriver: Better, Or Just Different? -- by Gil Tayar
Software Testing
Ad

More from Applitools (20)

PDF
Applitools Platform Pulse: What's New and What's Coming - July 2025
PDF
Code and No-Code Journeys: The Maintenance Shortcut
PDF
Code and No-Code Journeys: The Coverage Overlook
PDF
Creating Automated Tests with AI - Cory House - Applitools.pdf
PDF
Navigating EAA Compliance in Testing.pdf
PDF
AI-Assisted, AI-Augmented & Autonomous Testing
PDF
Code or No-Code Tests: Why Top Teams Choose Both
PDF
The ROI of AI-Powered Testing, presented by Applitools
PDF
Building No-code Autonomous E2E Tests_Applitools.pdf
PDF
Conquer 6 Testing Challenges_Applitools.pdf
PDF
Autonomous End-to-End Testing for Online Banking Applications Presented with ...
PDF
Playwright Visual Testing Best Practices, presented by Applitools
PDF
Cross-Browser and Cross-Device Testing | Applitools in Action
PDF
Advanced Debugging Techniques | Applitools in Action.pdf
PDF
AI-Powered Testing Strategies for the Seasonal Shopping Surge.pdf
PDF
Test Automation for Dynamic Applications _ Applitools in Action.pdf
PDF
Proven Approaches to AI-Powered E2E Testing.pdf
PDF
Applitools Autonomous 2.0 Sneak Peek.pdf
PDF
Building the Ideal CI-CD Pipeline_ Achieving Visual Perfection
PDF
Leveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Applitools Platform Pulse: What's New and What's Coming - July 2025
Code and No-Code Journeys: The Maintenance Shortcut
Code and No-Code Journeys: The Coverage Overlook
Creating Automated Tests with AI - Cory House - Applitools.pdf
Navigating EAA Compliance in Testing.pdf
AI-Assisted, AI-Augmented & Autonomous Testing
Code or No-Code Tests: Why Top Teams Choose Both
The ROI of AI-Powered Testing, presented by Applitools
Building No-code Autonomous E2E Tests_Applitools.pdf
Conquer 6 Testing Challenges_Applitools.pdf
Autonomous End-to-End Testing for Online Banking Applications Presented with ...
Playwright Visual Testing Best Practices, presented by Applitools
Cross-Browser and Cross-Device Testing | Applitools in Action
Advanced Debugging Techniques | Applitools in Action.pdf
AI-Powered Testing Strategies for the Seasonal Shopping Surge.pdf
Test Automation for Dynamic Applications _ Applitools in Action.pdf
Proven Approaches to AI-Powered E2E Testing.pdf
Applitools Autonomous 2.0 Sneak Peek.pdf
Building the Ideal CI-CD Pipeline_ Achieving Visual Perfection
Leveraging AI for Mobile App Testing on Real Devices | Applitools + Kobiton
Ad

Recently uploaded (20)

PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PDF
How to Choose the Right IT Partner for Your Business in Malaysia
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
CHAPTER 2 - PM Management and IT Context
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PDF
Digital Strategies for Manufacturing Companies
PPTX
Essential Infomation Tech presentation.pptx
PDF
Design an Analysis of Algorithms I-SECS-1021-03
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PPTX
Reimagine Home Health with the Power of Agentic AI​
PPTX
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
PDF
PTS Company Brochure 2025 (1).pdf.......
PDF
Softaken Excel to vCard Converter Software.pdf
PPTX
Operating system designcfffgfgggggggvggggggggg
PDF
Understanding Forklifts - TECH EHS Solution
PDF
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
PDF
Nekopoi APK 2025 free lastest update
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
Navsoft: AI-Powered Business Solutions & Custom Software Development
How to Choose the Right IT Partner for Your Business in Malaysia
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
CHAPTER 2 - PM Management and IT Context
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
Design an Analysis of Algorithms II-SECS-1021-03
Digital Strategies for Manufacturing Companies
Essential Infomation Tech presentation.pptx
Design an Analysis of Algorithms I-SECS-1021-03
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
Reimagine Home Health with the Power of Agentic AI​
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
PTS Company Brochure 2025 (1).pdf.......
Softaken Excel to vCard Converter Software.pdf
Operating system designcfffgfgggggggvggggggggg
Understanding Forklifts - TECH EHS Solution
SAP S4 Hana Brochure 3 (PTS SYSTEMS AND SOLUTIONS)
Nekopoi APK 2025 free lastest update
How to Migrate SBCGlobal Email to Yahoo Easily

Creating a flawless user experience, end to-end, functional to visual - Slides by Gil Tayar

  • 1. @giltayar Creating a Flawless User Experience, End-To-End, Functional to Visual Gil Tayar (@giltayar) April 2019 Github repo: https://github.com/applitools/cypress-applitools-webinar This presentation: http://bit.ly/cypress-applitools-webinar Gleb’s presentation: https://slides.com/bahmutov/flawless-tests 1
  • 2. @giltayar 2 VP of Engineering, Cypress.io Senior Architect, Applitools
  • 3. @giltayar Why Do We Write Tests? 3
  • 8. @giltayar Functional Testing Solve That ● I add/remove/refactor, run the tests, and voila! ● Fearless 8
  • 9. @giltayar And Cypress is the perfect tool for that! 9
  • 10. @giltayar (although I will let Gleb expound on that) 10
  • 11. @giltayar Except for one teeny tiny area of my code 11
  • 12. @giltayar HTML and CSS Markup When I change my HTML and CSS, do the pages still look like they should? ● Yes, the checkbox is disabled. But does it look disabled? ● In my todo row, when it’s completed, does it look striked out? ● Does the whole page look OK? ● After I create a new row, does it still look OK? 12
  • 13. @giltayar Visual testing enables you to… ● Add markup ● Remove markup ● Refactor markup Without Fear 13
  • 14. @giltayar And Applitools Eyes is the perfect tool for that! 14
  • 15. @giltayar Functional and Visual Tests enable you to cover your application cover to cover 15
  • 19. @giltayar How does one go about visually testing an app? ● Automate the browser, do what the user would: ○ Use Cypress! ● For each page you would like to visually test: ○ Navigate/click/type to it ○ Take a screenshot ○ Check that it’s OK 19
  • 20. @giltayar How would it look like? it('logs in', () => { cy.contains('a.nav-link', 'Sign in').click() cy.eyesCheckWindow ('Login page') const user = Cypress.env('user') cy.get('input[type="email"]' ).type(user.email) cy.get('input[type="password"]' ).type(user.password) cy.get('button[type="submit"]' ).click() cy.eyesCheckWindow ('Empty home page after login' ) }) 20
  • 21. @giltayar How would it look like? it('logs in', () => { cy.contains('a.nav-link', 'Sign in').click() cy.eyesCheckWindow ('Login page') const user = Cypress.env('user') cy.get('input[type="email"]').type(user.email) cy.get('input[type="password"]').type(user.password) cy.get('button[type="submit"]').click() cy.eyesCheckWindow ('Empty home page after login' ) }) 21 Actions
  • 22. @giltayar How would it look like? it('logs in', () => { cy.contains('a.nav-link', 'Sign in').click() cy.eyesCheckWindow('Login page') const user = Cypress.env('user') cy.get('input[type="email"]' ).type(user.email) cy.get('input[type="password"]' ).type(user.password) cy.get('button[type="submit"]' ).click() cy.eyesCheckWindow('Empty home page after login') }) 22 Screenshots
  • 23. @giltayar This is how test code looks like Navigate Click, type, click checkScreenshot Click, click, type checkScreenshot Type, click, click checkScreenshot Click, click, click checkScreenshot 23
  • 24. @giltayar How do we check that the screenshot is OK? You send us screenshots of your app We compare the screenshots with baseline images We report any differences found You accept or reject the differences
  • 26. @giltayar Building a UI that you use to accept or reject a difference 26
  • 30. @giltayar A Huge Difficulty: False Positives 30
  • 34. @giltayar But also what about…? ● Different browsers ○ Chrome, Firefox, Safari ● Different responsive widths and pixel densities ○ Smartphone width and pixel density ○ Tablet width ○ Regular desktop width ○ Retina display width and pixel density 34
  • 35. @giltayar So... Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 1024 Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 2500 Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 1024 … 35
  • 36. @giltayar Run each test ten times? 36
  • 37. @giltayar Run each test ten times? (not even with Cypress…) 37
  • 38. @giltayar Why is this not a problem in functional e2e tests? Because browsers have converged functionally 38
  • 39. @giltayar How do we solve this problem? We parallelize 39
  • 40. @giltayar Solution: Parallelizing the tests Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 1024 Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 1024 Navigate Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot Click, click, click checkScreenshot 2500 40
  • 42. @giltayar Parallelize the screenshots! Navigate Click, click, click checkScreenshot #1 Click, click, click checkScreenshot #2 Click, click, click checkScreenshot #3 Click, click, click checkScreenshot #4 ...768 ,1024,2500 ...768 ,1024,2500 ...768 ,1024,2500 ...768 ,1024,2500 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 screen #2 @ 768 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 screen #2 @ 768 42
  • 43. @giltayar How? DOM Snapshots! Navigate Click, click, click checkScreenshot #1 Click, click, click checkScreenshot #2 Click, click, click checkScreenshot #3 Click, click, click checkScreenshot #4 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 DOM Snapshot #1 Screenshots!43
  • 44. @giltayar How? DOM Snapshots! Navigate Click, click, click checkScreenshot #1 Click, click, click checkScreenshot #2 Click, click, click checkScreenshot #3 Click, click, click checkScreenshot #4 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 screen #1 @ 768 screen #1 @ 1024 screen #1 @ 2500 DOM Snapshot #1 Screenshots!44
  • 45. @giltayar The Applitools Visual Grid DOM Snapshot Screenshots Applitools Eyes Server 45
  • 46. @giltayar OK, OK. But how? How do I write tests? Show me some code! 46
  • 47. @giltayar Things we haven’t shown ● Take selective screenshot using selector ● Github and Bitbucket integration ● JIRA integration ● Shadow DOM and Canvas support: coming soon ● Ignore regions, floating ignore regions ● Layout mode! 47
  • 48. @giltayar Coming Soon ● A Cypress course in TestAutomationU ○ https://testautomationu.applitools.com/ ○ Written by yours truly 48
  • 49. @giltayar Thank You Github repo: https://github.com/applitools/cypress-applitools-webinar This presentation: http://bit.ly/cypress-applitools-webinar Gleb’s presentation: https://slides.com/bahmutov/flawless-tests 49