Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(test-runner): introduce pixelCount and pixelRatio options #12169

Merged
merged 2 commits into from
Feb 17, 2022

Commits on Feb 17, 2022

  1. feat(test-runner): introduce pixelCount and pixelRatio options

    This patch adds additional options to `toMatchSnapshot` method:
    - `pixelCount` - acceptable number of pixels that differ to still
      consider images equal.
    - `pixelRatio` - acceptable percentage of pixels that differ to still
      consider images equal.
    
    Since some anti-aliasing artifacts still can cripple in, we default
    `pixelCount` to some arbitrary small number - `17` - to improve
    tolerance.
    
    Fixes microsoft#12167, microsoft#10219
    aslushnikov committed Feb 17, 2022
    Configuration menu
    Copy the full SHA
    bd8727b View commit details
    Browse the repository at this point in the history
  2. address comments

    aslushnikov committed Feb 17, 2022
    Configuration menu
    Copy the full SHA
    9a9091a View commit details
    Browse the repository at this point in the history