public class ImageComparison extends Object
| Constructor and Description |
|---|
ImageComparison() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
compareImages(BufferedImage referenceImage,
BufferedImage screenshotImage,
double errorTolerance) |
boolean |
imageEqualToReference(BufferedImage screenshotImage,
BufferedImage referenceImage,
String referenceFileName,
double errorTolerance) |
boolean |
imageEqualToReference(BufferedImage screenshotImage,
String referenceFileId,
double errorTolerance,
org.openqa.selenium.Capabilities capabilities)
Compare image [name] to image under /reference/.
|
public boolean imageEqualToReference(BufferedImage screenshotImage, String referenceFileId, double errorTolerance, org.openqa.selenium.Capabilities capabilities) throws IOException
screenshotImage - Image of canvas (must have proper dimensions)referenceFileId - File id for this image without .png extensionerrorTolerance - Allowed RGB error for a macroblock (value range 0-1 default
0.025 == 2.5%)capabilities - browser capabilitiesIOExceptionpublic boolean imageEqualToReference(BufferedImage screenshotImage, BufferedImage referenceImage, String referenceFileName, double errorTolerance)
public boolean compareImages(BufferedImage referenceImage, BufferedImage screenshotImage, double errorTolerance)
Copyright © 2018. All rights reserved.