SlideShare a Scribd company logo
1 of 4
Image recognition using TestComplete™
                 Testcomplete™ can be used to automate testing of Web & windows applications. Although
                 TestComplete™ supports major standard controls, windows and objects in a wide variety of
                 applications, there are some controls and windows that cannot be recognized by Test
                 Complete directly. For example cells in few grid controls, buttons in some flash applications
                 may not be accessible by TestComplete™. Handling TestComplete™ during such conditions
                 makes automation little challenging.

                 It is possible to overcome these kinds of difficulties by using a low-level recording approach
                 to test such applications. The main drawback of such an approach is that the script will
                 require several changes even for a simple UI change in the application. So, creating and
                 maintaining a stable script with this method is also not possible. Low-level Recording will be
                 usually used in TestComplete™ for automating Testing in browsers other than IE and
                 Firefox. Any application that needs to be tested in other browsers (such as Google Chrome
                 or Opera) using TestComplete™ automation needs to approach low level recording
                 technique.

                 You can also look at utilizing Image recognition feature of TestComplete™. Let‟s consider a
                 test application containing a button which is unfortunately not recognized by
                 TestComplete™. In this situation, it is possible in TestComplete™ to capture the image of
                 this button and give it as an input for testing. TestComplete™ will search for this button
                 using its image & recognize the button as a rectangular image object. Now we can get the
                 position of the button and calculate X-Y coordinates of the center point of this object. By
                 getting these coordinates, the action CLICK can be performed to trigger the click action of
                 the mouse.

                 To click a button,




Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
To enter value into a Textbox




                How to find an Image in an object?

                One needs to use the method named „Regions.Find‟ inorder to find the image of object
                (which is not auto recognized by TestComplete™). Following is the syntax for this method

                         Regions.Find(PictureTosearchin, PictureToSearchFor)

                This method searches for an image on other image or object. And it returns the identified
                rectangular image object. It has two required parameters.

                         PictureToSearchin – Page or Window object, in which the object is located.

                         PictureToSearchFor – This is the image name of the Test Object. This image
                         should have been stored in Regions Items of Testcomplete™.

                Consider an example to explore usage of Image Recognition in TestComplete™. The
                following screenshot shows an Add-on that needs to be installed from Google Chrome. User
                needs to click button “Add to Chrome” inorder to install add-on from Google Chrome




Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
browser.



                Since Google Chrome is not currently supported by TestComplete™, we can make use of
                image recognition feature available in TestComplete™ to trigger the Button click action
                automated from Google Chrome browser, by identifying the position of the button and
                triggering click action on it

                     1) Store the rectangular image of this button in Region items of test complete project.
                        In the below example, Image name is stored as „Add_To_Chrome‟




                     2) To find & click this image object on chrome window, we can use the following script.




Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
3) This button clicks on the center position of the button.




                        Hence using the above script, TestComplete™ can automate the test for clicking
                        button „Add to Chrome‟ executed from Google Chrome browser. Using the same
                        method, it is possible find any unrecognized object and then can perform any actions
                        on the recognized images.




Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER

More Related Content

Viewers also liked

TestComplete 7.50 New Features
TestComplete 7.50 New FeaturesTestComplete 7.50 New Features
TestComplete 7.50 New FeaturesVlad Kuznetsov
 
social prez - mpcc - mholterhaus
social prez - mpcc - mholterhaussocial prez - mpcc - mholterhaus
social prez - mpcc - mholterhausmholterhaus
 
Keyword Driven Testing using TestComplete
Keyword Driven Testing using TestCompleteKeyword Driven Testing using TestComplete
Keyword Driven Testing using TestCompletesrivinayak
 
Web Service Testing using TestComplete
Web Service Testing using TestCompleteWeb Service Testing using TestComplete
Web Service Testing using TestCompletesrivinayak
 
Keyword-driven Test Automation Framework
Keyword-driven Test Automation FrameworkKeyword-driven Test Automation Framework
Keyword-driven Test Automation FrameworkMikhail Subach
 

Viewers also liked (6)

Test Complete
Test CompleteTest Complete
Test Complete
 
TestComplete 7.50 New Features
TestComplete 7.50 New FeaturesTestComplete 7.50 New Features
TestComplete 7.50 New Features
 
social prez - mpcc - mholterhaus
social prez - mpcc - mholterhaussocial prez - mpcc - mholterhaus
social prez - mpcc - mholterhaus
 
Keyword Driven Testing using TestComplete
Keyword Driven Testing using TestCompleteKeyword Driven Testing using TestComplete
Keyword Driven Testing using TestComplete
 
Web Service Testing using TestComplete
Web Service Testing using TestCompleteWeb Service Testing using TestComplete
Web Service Testing using TestComplete
 
Keyword-driven Test Automation Framework
Keyword-driven Test Automation FrameworkKeyword-driven Test Automation Framework
Keyword-driven Test Automation Framework
 

Recently uploaded

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 

Recently uploaded (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 

Image Recognition Automated QA - TestComplete™

  • 1. Image recognition using TestComplete™ Testcomplete™ can be used to automate testing of Web & windows applications. Although TestComplete™ supports major standard controls, windows and objects in a wide variety of applications, there are some controls and windows that cannot be recognized by Test Complete directly. For example cells in few grid controls, buttons in some flash applications may not be accessible by TestComplete™. Handling TestComplete™ during such conditions makes automation little challenging. It is possible to overcome these kinds of difficulties by using a low-level recording approach to test such applications. The main drawback of such an approach is that the script will require several changes even for a simple UI change in the application. So, creating and maintaining a stable script with this method is also not possible. Low-level Recording will be usually used in TestComplete™ for automating Testing in browsers other than IE and Firefox. Any application that needs to be tested in other browsers (such as Google Chrome or Opera) using TestComplete™ automation needs to approach low level recording technique. You can also look at utilizing Image recognition feature of TestComplete™. Let‟s consider a test application containing a button which is unfortunately not recognized by TestComplete™. In this situation, it is possible in TestComplete™ to capture the image of this button and give it as an input for testing. TestComplete™ will search for this button using its image & recognize the button as a rectangular image object. Now we can get the position of the button and calculate X-Y coordinates of the center point of this object. By getting these coordinates, the action CLICK can be performed to trigger the click action of the mouse. To click a button, Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
  • 2. To enter value into a Textbox How to find an Image in an object? One needs to use the method named „Regions.Find‟ inorder to find the image of object (which is not auto recognized by TestComplete™). Following is the syntax for this method Regions.Find(PictureTosearchin, PictureToSearchFor) This method searches for an image on other image or object. And it returns the identified rectangular image object. It has two required parameters. PictureToSearchin – Page or Window object, in which the object is located. PictureToSearchFor – This is the image name of the Test Object. This image should have been stored in Regions Items of Testcomplete™. Consider an example to explore usage of Image Recognition in TestComplete™. The following screenshot shows an Add-on that needs to be installed from Google Chrome. User needs to click button “Add to Chrome” inorder to install add-on from Google Chrome Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
  • 3. browser. Since Google Chrome is not currently supported by TestComplete™, we can make use of image recognition feature available in TestComplete™ to trigger the Button click action automated from Google Chrome browser, by identifying the position of the button and triggering click action on it 1) Store the rectangular image of this button in Region items of test complete project. In the below example, Image name is stored as „Add_To_Chrome‟ 2) To find & click this image object on chrome window, we can use the following script. Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER
  • 4. 3) This button clicks on the center position of the button. Hence using the above script, TestComplete™ can automate the test for clicking button „Add to Chrome‟ executed from Google Chrome browser. Using the same method, it is possible find any unrecognized object and then can perform any actions on the recognized images. Visit IVESIA’S WEBSITE Follow us at LINKEDIN and TWITTER