automating visual regression testing with...

141
Automating Visual Regression Testing with BackstopJS @angelariggs_ PNSQC | October 2018

Upload: others

Post on 27-May-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

Automating Visual Regression Testing

with BackstopJS@angelariggs_ PNSQC | October 2018

Page 2: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

How It’s Useful and

How We Used It

@angelariggs_ PNSQC | October 2018

Page 3: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Front-end testing is hard

Page 4: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Mobile Desktop

Tablet

Page 5: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Fonts Images Layout

Page 6: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Fragile CSS ecosystems

Page 7: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 8: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Front-end testing is hard

Page 9: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

The Problem: Disappearing content

on deploys

Page 10: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Manual testing was tedious & ineffective

Page 11: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

BackstopJS

Page 12: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Open-source package

Page 13: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Open-source package - Before & after screenshots

Page 14: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Open-source package - Before & after screenshots - Chrome Headless, PhantomJS, or Slimer

Page 15: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Open-source package - Before & after screenshots - Chrome Headless, PhantomJS, or Slimer - UI simulations

Page 16: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Open-source package - Before & after screenshots - Chrome Headless, PhantomJS, or Slimer - UI simulations - HTML report for comparison

Page 17: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 18: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 19: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 20: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 21: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 22: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 23: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 24: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 25: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 26: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 27: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 28: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 29: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 30: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 31: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 32: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Success: Automated visual regression testing

helped us find and fix regressions before it became the client’s problem

Page 33: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

But…

Page 34: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 35: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 36: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 37: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 38: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 39: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 40: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

70 URLs

Page 41: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

70 URLs x 3 CSS selectors

Page 42: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

70 URLs x 3 CSS selectors x 2 viewports

Page 43: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

70 URLs x 3 CSS selectors x 2 viewports 420 screenshots

Page 44: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 45: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references

Page 46: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes

Page 47: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys

Page 48: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests

Page 49: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests 5. Go have lunch

Page 50: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests 5. Go have lunch 6. Review report

Page 51: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests 5. Go have lunch 6. Review report 7. Feedback to developer

Page 52: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references* 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests* 5. Go have lunch 6. Review report 7. Feedback to developer

Page 53: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

* Remember to include “no-timeout” parameter

Page 54: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 55: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests 5. Go have lunch 6. Review report* 7. Feedback to developer

Page 56: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

“Automated”

Page 57: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Narrowing the Scope

Page 58: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 59: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 60: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Increase viewport height to grab entire page - One CSS selector per URL - Remove URLs that use the same template

Page 61: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

420 screenshots

Page 62: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

420 screenshots ➡ 40 screenshots

Page 63: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 64: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run screenshot references* 2. Go play Towerfall for 35 minutes 3. Developer deploys 4. Run screenshot tests* 5. Go have lunch 6. Review report* 7. Feedback to developer

Page 65: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Tester runs screenshot references 2. Developer deploys 3. Tester runs screenshot test 4. Review report 5. Feedback to developer

Page 66: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Smoke test for all staging and prod deploys

Page 67: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

But…

Page 68: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Four separate configuration files

Page 69: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Four separate configuration files - Lots of back & forth between developer and tester

Page 70: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 71: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

More automated Still tedious

Page 72: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Developers oversee deploys

Page 73: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Developers oversee deploys - Developers should oversee deploy tests

Page 74: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Make it Easy

Page 75: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Custom JavaScript configuration

Page 76: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 77: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 78: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 79: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 80: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 81: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 82: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 83: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 84: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 85: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 86: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 87: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 88: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

--env=prod

Page 89: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 90: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 91: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 92: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 93: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 94: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 95: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 96: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 97: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 98: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 99: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 100: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 101: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 102: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 103: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 104: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 105: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 106: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 107: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

4 config files

Page 108: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

4 config files ➡ 1 config file

Page 109: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- detailed README for setup and use - template repo for quick setup on new projects

Page 110: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 111: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

But…

Page 112: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

backstop reference--configPath=backstop.js--pathFile=paths --env=prod

Page 113: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

backstop reference--configPath=backstop.js--pathFile=paths --env=prod

Page 114: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

backstop reference--configPath=backstop.js--pathFile=paths --env=prod

Page 115: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

backstop reference--configPath=backstop.js--pathFile=paths --env=prod

Page 116: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

backstop reference--configPath=backstop.js--pathFile=paths --env=prod--refHost=http://prod-site.com

Page 117: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 118: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

make prod-reference

Page 119: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

make prod-test

Page 120: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Page 121: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Smoke tests for all deploys on all projects

Page 122: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Dev runs references 2. Dev deploys 3. Dev runs tests 4. Dev reviews the report

Page 123: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Smoke tests for all deploys on all projects - Regression test during feature testing

Page 124: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Run references on master branch 2. Check out feature branch 3. Run tests on feature branch 4. Review the report

Page 125: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

- Smoke tests for all deploys on all projects - Regression test during feature testing - Local use during feature development

Page 126: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

1. Create and check out feature branch 2. Run references on fresh branch 3. Do local development 4. Run tests on branch periodically 5. Review report

Page 127: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Front-end testing is hard easy

Page 128: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Problem ➡ Solution

Page 129: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Problem ➡ Idea

Page 130: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Problem ➡ Idea ➡ Iterate

Page 131: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Problem ➡ Idea ➡ Iterate ➡ Iterate

Page 132: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Problem ➡ Idea ➡ Iterate ➡ Iterate ➡ Solution

Page 133: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

BackstopJS

Page 134: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

BackstopJS ➡ Refined configuration

Page 135: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Refined config ➡ Customized config

Page 136: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Automation is useful*

Page 137: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Find the right automation solution for your problem

Page 138: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Automated testing requires manual work

Page 139: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

@angelariggs_ PNSQC | 2018

Front-end testing is easy easier with the right automation

Page 140: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

https://github.com/angelariggs/visual-regression

@angelariggs_ PNSQC | October 2018

Page 141: Automating Visual Regression Testing with BackstopJSuploads.pnsqc.org/2018/papers/35-Riggs-Automating... · @angelariggs_ PNSQC | 2018 1. Run screenshot references* 2. Go play Towerfall

Thank you!

@angelariggs_ PNSQC | October 2018