Skip to content
This repository was archived by the owner on Aug 8, 2022. It is now read-only.

Add ability for Testify to generate companion diff images for failed tests#209

Merged
DanielJette merged 1 commit intomasterfrom
206-generate-diffs
Mar 24, 2021
Merged

Add ability for Testify to generate companion diff images for failed tests#209
DanielJette merged 1 commit intomasterfrom
206-generate-diffs

Conversation

@DanielJette
Copy link
Copy Markdown
Contributor

@DanielJette DanielJette commented Mar 18, 2021

What does this change accomplish?

Resolves #206

How have you achieved it?

⚠️ Based on #208. You can review only 510d588 for this PR

Added TestifyFeatures.GenerateDiffs. When enabled, will output a .diff.png alongside existing baseline images. These images are high-contrast images where each difference, regardless of how minor, are indicated in red against a black background. See the generateDiffs test in ScreenshotRuleExampleTests for an example. Diff images will be pulled from the device when running screenshotPull.

Tophat instructions

See the generateDiffs test in ScreenshotRuleExampleTests for an example.

image

Notice

This change must keep master in a shippable state; it may be shipped without further notice.

@DanielJette DanielJette force-pushed the 206-generate-diffs branch 3 times, most recently from 7ca15e2 to 0100844 Compare March 23, 2021 14:34
Copy link
Copy Markdown

@realdm realdm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code and Screenshots LGTM

@DanielJette DanielJette merged commit c0aecaa into master Mar 24, 2021
@DanielJette DanielJette deleted the 206-generate-diffs branch March 24, 2021 17:10
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Generate high-contrast diffs

3 participants