Compare images. Fail if images more different than threshold.
Make sure you have imagemagick (convert)
Version | 0.3 |
---|---|
Bundle | tools |
Categories | Internal |
Authors | Ville Rantanen (ville.rantanen@helsinki.fi) |
Issue tracker | View/Report issues |
Requires | bash ; bc ; imagemagick (DEB) |
Source files | component.xml compare.sh |
Usage | Example with default values |
Name | Type | Mandatory | Description |
---|---|---|---|
expected | Image | Mandatory | Expected image |
image | Image | Mandatory | Tested image |
Name | Type | Default | Description |
---|---|---|---|
failOnSimilar | boolean | false | Invert the comparison, set to true if images are expected to differ. |
threshold | float | 0.9 | Accepted correlation treshold. Higher value allows smaller difference. |
width | int | 0 | Resize to square of given width before comparison |
Test case | Parameters▼ | IN expected |
IN image |
|||
---|---|---|---|---|---|---|
case1_same | properties | expected | image | |||
width=320 |
||||||
case2_differ | properties | expected | image | |||
threshold=0.95, |