Forum Discussion

burnettm's avatar
burnettm
Senior Member
5 years ago
Solved

Pixel and Color tolerance

Hi, I'm very new to Test Complete and am using it with no coding experience, so I apologise in advance if this is a stupid question.

 

We have a desktop application and we are using TC to automate some UI test cases. As 2 of the 3 testers have no coding experience, we mainly use keyword tests to create these tests. 

 

Region checkpoints are being used all the time. What I have trouble with daily is I will capture a region checkpoint (with pixel tolerance at 0, and color at around 17%), and although I execute the test immediately it always fails the first time because the 'images are not equal, pixel difference is * and color difference is *'. 

 

What I don't get is why would there be any differences in pixels/colors when the desktop application has been sitting opened, unchanged, between capturing that first region checkpoint and the immediate execution run of that checkpoint? It's extremely slow going capturing the region, and then having to run each one, letting TC auto correct the pixel/color tolerance before moving onto the next checkpoint.

 

Any help would be appreciated. Thanks in advance.

  • There are also, always, minor variant differences even in the same object on the same system.  Its for this reason I don't rely on Image comparisons unless there is no other way to do so.  So, for example, if all you're doing is checking the text in an object, do a propery checkpoint on the WndCaption or similar property rather than an image comparison.

2 Replies

  • Bobik's avatar
    Bobik
    Frequent Contributor

    I guess your application highlights a control when you move the mouse over it.

    So when you captured a region checkpoint the control was highlighted because you picked it by the mouse. And during playback, I think mouse pointer is pointing somewhere else. 

    In this case, play your test and then click "Update checkpoint" link in Details of the error message in the log.

    • tristaanogre's avatar
      tristaanogre
      Esteemed Contributor

      There are also, always, minor variant differences even in the same object on the same system.  Its for this reason I don't rely on Image comparisons unless there is no other way to do so.  So, for example, if all you're doing is checking the text in an object, do a propery checkpoint on the WndCaption or similar property rather than an image comparison.