1.1.0-rc01
1.1.0-rc01
Library
Bug fixes
-
#228, #215
Account for uneven processing chunk sizes. As Testify processes, it divides the images into chunks for faster, parallel processing.
A bug in the original code assumed that each processing chunk would be equally sized. This caused an out-of-bounds exception in any case where the number of pixels in the image could not be evenly divided. -
#216
You can now useScreenshotRule.setExactness()in conjunction withScreenshotRule.defineExclusionRects(). You can now define both an exclusion area and an exactness threshold.
Added
- Method
ScreenshotRule.getExactness():Float?added.
Changes
-
Method
ScreenshotRule.setExactness(exactness: Float?): ScreenshotRule<T>now accepts a nullable value. -
TestifyFeatures.GenerateDiffsnow visualizes exclusion regions and the exactness tolerance.
When enabled, GenerateDiffs will write a companion image for your screenshot test which can help you more easily
identify which areas of your test have triggered the screenshot failure.
Diff files are only generated for failing tests.
The generated file will be created in the same directory as your baseline images. Diff files can be pulled from
the device using:screenshotPull.- Black pixels are identical between the baseline and test image
- Grey pixels have been excluded from the comparison
- Yellow pixels are different, but within the Exactness threshold
- Red pixels are different
-
Method
DeviceIdentifier.getDeviceDimensions(context: Context): Pair<Int, Int>is now public.