Forum Discussion
Yes, you can use the Picture.Difference method... that's what I meant by image comparison. However, the initial "PictureObj" in your example STILL needs to be something gathered from the automation in order to do the comparison and, on the fly in the code, you can't grab the images from the Visualizer or from the NameMapping repository. Those images are not available at runtime.
But... that doesn't really seem to be the problem... you mention something about a difference in resolution causing a click to fail. That has nothing to do with image capture... that has to do with how you are coding your clicks and how you are constructing your tests.
First of all, you should ALWAYS try to make sure your dev environment and your execution environment match as much as possible.
Secondly, you should avoid, as much as possible, any code execution which requires a hard-coded pixel screen location.
So... it seems that you're conflating problems here... you're trying to solve a "unable to click" problem with something to do with image capture.
It would be helpful if, for those two scenarios, you give us some code example of what you're attempting. Perhaps we can resolve your problem without having to go through image processing.
Sorry for getting deviated from my question with the example.
I'm looking for a feature in which the Images are also stored with object properites (NameMapping).
In execution, As we compare Object Properties and Perform methods on it. Similarly, We can verify the Images too.
Yes, We can do that currently by adding all the Images on Regions and Compare on Run time.
Instead, Like Expected Object Properties like IdStr, Object Type are stored in NameMapping.
Expected Image can also be stored during first capture in NameMapping.
A Comparision method for Images can be created based on Every Object without manually adding Images to regions.
In a Simple Way, If Images can be added to regions/NameMapping/ Visualizer using Object properties.
Image Checkpoint or Image Comparision can happen for every step without creating a seperate feature.
Option for Image validation on object level can be create for successful Visual validation.
ExpectedImage = Namemapping.Sys.Myapplication.LoginButton.StoredImage
Method : StoredImage
ActualImage = NameMapping.Sys.Application.LoginButton.RuntimeImage
Method:RunTimeImage
If ExpectedImage = ActualImage , Visual Validation will be sucessful.
Summary.
Storing Images in Regions on Object level
Comparing Images with Object Level
Finding an Alternative for applitools within TestComplete by creating few new methods.
Sorry, If my explaination was not clear.
Thanks for everyone who responded.
- tristaanogre5 years agoEsteemed Contributor
Currently, there is no method by which images can be utilized directly from Visualizer and NameMapping in comparing images on screen. This, I believe, was already mentioned above by AlexKaras . This, I believe, answers your question: You will need to create a repository of baseline images to use in your comparisons so that you can either use the PictureObj.Difference method or a Region Checkpoint to compare images.
If you want such a thing added, there is a feature request area here on the community that you can request it. However, placing a request does not mean it willl get added/created/developed in the short term... meaning, you will STILL need to do the work to create that image respository. - TanyaYatskovska5 years agoSmartBear Alumni (Retired)
HI Vallalarasu_P,
I have nothing to add. As Robert said, you can try doing image comparison. Also, it makes sense to consider doing manual testing for this part.
Related Content
- 3 years agoparisgambit
- 11 months agoMW_Didata
- 11 months agoBob_C
Recent Discussions
- 2 days agojstaehlin