Code coverage using ui.tests module & automation Testcases | Community
Skip to main content
Level 5
April 15, 2024
Solved

Code coverage using ui.tests module & automation Testcases

  • April 15, 2024
  • 1 reply
  • 468 views

Hi Team

Can we use  ui.tests module for code coverage & automation Testcases executions.

 

Can you please let me know, what we can do using ui.test modules and difference Cypress based UI tests( ui.tests.cypress & Selenium based UI tests(ui.tests.wdio) which is recommended to achieve the code coverage and automation testcase.

 

which maven command need to use to work on in this module? 

mvn clean test or mvn clean install 

 

Regards

Vara

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by EstebanBustamante

Hi,


In short, yes, you could potentially use the ui.test module to write your automation tests. Adobe provides several flavors of common test automation frameworks such as Cypress and Selenium. It's up to you to decide which one you prefer to use based on your unique situation. The advantage of having tests within this module is that they will be triggered during a regular deployment if you are using AMS (Adobe Managed Services).

 

To check your test locally, it will vary on which technology you choose, for example, for Cypress, you could use the following command:

  1. Build the Docker UI test image with the below command
    mvn clean package -Pui-tests-docker-build
    
     
  2. Run the test
    mvn verify -Pui-tests-docker-execution -DAEM_AUTHOR_URL=https://author.my-deployment.com -DAEM_AUTHOR_USERNAME=<PASS> -DAEM_AUTHOR_PASSWORD=<PASS>


Please check the official documentation that will solve all of your doubts about how to install and use them: https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service/content/implementing/using-cloud-manager/test-results/functional-testing/ui-testing#building-ui-tests 

 

 

Hope this helps.

1 reply

EstebanBustamante
Community Advisor and Adobe Champion
EstebanBustamanteCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
April 15, 2024

Hi,


In short, yes, you could potentially use the ui.test module to write your automation tests. Adobe provides several flavors of common test automation frameworks such as Cypress and Selenium. It's up to you to decide which one you prefer to use based on your unique situation. The advantage of having tests within this module is that they will be triggered during a regular deployment if you are using AMS (Adobe Managed Services).

 

To check your test locally, it will vary on which technology you choose, for example, for Cypress, you could use the following command:

  1. Build the Docker UI test image with the below command
    mvn clean package -Pui-tests-docker-build
    
     
  2. Run the test
    mvn verify -Pui-tests-docker-execution -DAEM_AUTHOR_URL=https://author.my-deployment.com -DAEM_AUTHOR_USERNAME=<PASS> -DAEM_AUTHOR_PASSWORD=<PASS>


Please check the official documentation that will solve all of your doubts about how to install and use them: https://experienceleague.adobe.com/en/docs/experience-manager-cloud-service/content/implementing/using-cloud-manager/test-results/functional-testing/ui-testing#building-ui-tests 

 

 

Hope this helps.

Esteban Bustamante