MCPcopy Create free account
hub / github.com/Kitware/VTK / assertImageMatch

Method assertImageMatch

Wrapping/Python/vtkmodules/test/Testing.py:265–276  ·  view source on GitHub ↗

Throw an error if a rendering in the render window does not match the baseline image. This method accepts a threshold keyword argument (with a default of 0.15) that specifies how different a baseline may be before causing a failure.

(self, renwin, baseline, **kwargs)

Source from the content-addressed store, hash-verified

263 return events
264
265 def assertImageMatch(self, renwin, baseline, **kwargs):
266 """Throw an error if a rendering in the render window does not match the baseline image.
267
268 This method accepts a threshold keyword argument (with a default of 0.15)
269 that specifies how different a baseline may be before causing a failure.
270 """
271 absoluteBaseline = baseline
272 try:
273 open(absoluteBaseline, 'r')
274 except:
275 absoluteBaseline = getAbsImagePath(baseline)
276 compareImage(renwin, absoluteBaseline, **kwargs)
277
278def interact():
279 """Interacts with the user if necessary. """

Callers 2

test0Method · 0.80
test1Method · 0.80

Calls 2

getAbsImagePathFunction · 0.85
compareImageFunction · 0.85

Tested by

no test coverage detected