Hi Joachim,
The screenshots of the "normal" part of the tested software pass the tests, but screenshots made of the part of the software, that has some sort of Internet Explorer 9 as base still differ.
...
The problem is, that all settings are the same on my local pc (where tests are written / recorded) and the pc where the tests are run. |
The problem is not in your system settings, they are fine. The problem is in the way the "IE 9" part of your AUT renders the fonts. As I said in my previous post, IE 9 -- both stand-alone and integrated into your AUT -- uses font smoothing even if it's disabled system-wise. Smooth fonts are rendered with mixed colors, and this causes problems with pixelwise image comparisons.
I guess, the baseline screenshot (the one on the left, with sharp fonts) was captured from either the "normal" part of your AUT, or an earlier IE version (e.g. 6) that doesn't have the described issue. That's why, the font rendering in the baseline and actual screenshots differs, and the comparison fails.
So would one possible solution then be to activate cleartype in windows (and update all screenshots)? |
No, you need to use sharp fonts to compare images, because they provide a more stable image comparison, while smooth fonts do not.
To work around the font smoothing issue in the "Internet Explorer" part of your AUT, you can use one of the following:
– Use
this technique to disable font smoothing in IE 9 (both stand-alone and integrated in your AUT) on all machines where the test is run. This should make fonts in the "IE" part of your AUT sharp like on the left picture.
– Downgrade from IE 9 to IE 8 on all machines where this test is run, and turn off its ClearType in Internet Options > Advanced > Multimedia. This should also make fonts in the "IE" part of your AUT sharp.
If neither is an option for you, you'll have to set the pixel and color tolerance for the checkpoints in order for the "IE" screenshots to pass the check.
Having said that, may I ask you what you are using region checkpoints for at all? If your goal is to compare some
text in the images, there are way more effective solutions like getting the text using methods and properties of the test objects in your application,
Text Recognition, etc.