SoCreate/angular-playground

--check-visual-regressions should fail when some snapshots are missing

georgms opened this issue · 1 comments

Versions

7.1.1
     _                      _                 ____ _     ___
    / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
   / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
  / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
 /_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
                |___/
    

Angular CLI: 10.1.4
Node: 12.20.0
OS: linux x64

Angular: 10.1.4
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, localize, platform-browser
... platform-browser-dynamic, router
Ivy Workspace: <error>

Package                            Version
------------------------------------------------------------
@angular-devkit/architect          0.1001.4
@angular-devkit/build-angular      0.1001.4
@angular-devkit/core               10.1.4
@angular-devkit/schematics         10.1.4
@angular/cdk                       10.2.3
@angular/material                  10.2.3
@angular/material-moment-adapter   10.2.3
@schematics/angular                10.1.4
@schematics/update                 0.1001.4
rxjs                               6.6.2
typescript                         4.0.3
webpack                            4.44.1

Repro steps

  • npx angular-playground --check-visual-regressions for the first time, ie. with no existing snapshots
  • Accidentally delete one of the snapshots.
  • npx angular-playground --check-visual-regressions

Observed Behavior

Command does not fail.

Desired Behavior

Command should fail.

Any other details that may be useful (optional)

My worry in the described scenario is that, if I accidentally one of the snapshots, I will never become aware of some visual regressions since the command just passes and does not detect that a snapshot is completely missing.

We would be open to taking a PR for fixing this issue if you would like to submit one.