Automation Testing

Using Selenium and Maven with Applitools

By Test Guild
  • Share:
Join the Guild for FREE

I recently interviewed Adam Carmi from Applitools on my TestTalks Podcast, and also created a blog post about visual validation testing, so I thought since we're talking about something that is a very visual activity, it would make sense to create a video as well.

In this video, I'll show you how easy it is to get started using Applitools, and add some` visual verifications to an existing test script. Applitools supports a bunch of frameworks and languages, but for demonstration purposes I'll be using Selenium script using Java and Maven. This is my first time ever using Applitools, so it should give you an idea of how easy it is to use and get started with.


  • Select your automation environment
    • Selenium (including Protractor & Capybara)
    • Appium
    • HP UFT / QTP
    • Microsoft CodedUI
    • Other


  • Select your development language:
    • Java
    • Ruby
    • Python
    • .Net
    • JS
    • PHP

     

  • Install SDK:


 

I chose Java so I have two options, Maven of download the Applitools Eyes Java Selenium SDK Jar file.

I'm using Maven, so I'll add the following dependency to my pom.xml file:

<dependency>

<groupId>com.applitools</groupId>

<artifactId>eyes-selenium-java</artifactId>

<version>RELEASE</version>

</dependency>

 

  • Build your first test

 


 


  • Analyze Test Results

The first time you run the test, Applitools will create a baseline image and store it on their cloud based server.

If you run the test again, another image will be captured and compared to the baseline. If any differences are found they will be highlighted as conflicts.

To see this, rerun our sample test script. Notice that an error occurred. If you look at the assertion error there is a URL to the Applitools image that contains the conflict. Let's navigate to it.


The image check will show any conflicts found.


At that point you have a few options:

  • Accept the change
  • Reject the change
  • Report a bug
  • Add some ignore regions over any dynamic data that your application might have


Comments are closed.

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

Leveraging AI and Playwright for Test Case Generation

Posted on 11/22/2024

Two BIG trends the past few years in the software testing space been ...

Symbolic AI vs. Gen AI: The Dynamic Duo in Test Automation

Posted on 09/23/2024

You've probably been having conversations lately about whether to use AI for testing. ...

8 Special Ops Principles for Automation Testing

Posted on 08/01/2024

I recently had a conversation, with Alex “ZAP” Chernyak about his journey to ...

Sponsor The Industry-Standard E2E Automation Testing Annual Online Event (Limited Spots Left) - Reach Out Now >>