Viewing differences of failed screenshot verification points

Last edited on

Overview

When screenshot verification points (VP) fail the Squish IDE offers to view the differences.

To view the differences either open the context menu of the respective entry in the Test Results view and choose "View Screenshot Differences" or click on the button with the tooltip "View Screenshot Differences":

Viewing screenshot VP differences from the Squish IDE

The differences of the screenshots are visually marked by red borders:

Be sure to resize the differences viewer or to scroll inside it to see all the differences in comparison to your screenshot VP.

Note that sometimes the differences are so small that the human eye cannot see them. Such minimal pixel differences can occur due to various factors (graphics card hardware and driver, operating system, anti-aliasing, etc.).

When you encounter such minimal differences it may work to configure a comparison mode other than "Strict" for the verification point. (See Image comparison modes in screenshot verification points .)

Viewing screenshot VP differences without the Squish IDE

The screenshot verification point differences viewer can be invoked from the command line, too.

The general syntax is as:

<SQUISH_DIR>/bin/vpdiff vpfile objectName [imagefile] [output [--highlights]]

For example:

"C:\Squish\bin\vpdiff" "suite_mine\tst_case1\verificationPoints\SVP1" ":MyObject" "suite_mine\tst_case1\verificationPoints\SVP1\failedImages\failed_1.png"
In cmd.exe or a shell

Creating an image with the differences:

"C:\Squish\bin\vpdiff" "suite_mine\tst_case1\verificationPoints\SVP1" ":MyObject" "suite_mine\tst_case1\verificationPoints\SVP1\failedImages\failed_1.png" "diff_image.png"
In cmd.exe or a shell

Creating an image with the differences being highlighted:

"C:\Squish\bin\vpdiff" "suite_mine\tst_case1\verificationPoints\SVP1" ":MyObject" "suite_mine\tst_case1\verificationPoints\SVP1\failedImages\failed_1.png" "diff_image.png"
--highlights
In cmd.exe or a shell