Execute Automated Testing in 3 Steps With Katalon Automation Recorder
Execute Automated Testing in 3 Steps With Katalon Automation Recorder
This article introduces automated testing, its challenges, and three easy steps to get started saving time by automating your software testing.
Join the DZone community and get the full member experience.Join For Free
1. Automated Testing Introduction
Automated testing is a method using an automated testing tool to write and execute automated test cases/test suites on a software application, comparing the actual results to the expected behavior and creating test reports.
In a nutshell, automated test scripts are the scripts prepared before running a test. When needed, these scripts will be executed the code of a web application to check whether it meets the requirements or not.
When it comes to automated testing, it’s hard for testers to be good at it without programming skills. But over time, testing tools have matured to simplify the process of testing. There are a lot of codeless tools on the market providing a graphical environment so that testers can easily create test cases. One of these tools is Katalon Recorder (a perfect successor to Selenium IDE), which will be mentioned as the comprehensive solution in this post.
Automated testing helps eliminate tasks that are too time-consuming and laborious to be performed manually, plus, automated tests can be run repeatedly once they have been created. In other words, automated testing helps increase the effectiveness and efficiency of software testing.
2. The Challenges of Executing Automated Tests
As I stated above about the complexity when running tests with a lack of programming knowledge, there are still so many other challenges:
- Preparing test scripts
In automated testing, a test script is a short program written in a programing language; that’s one of the reasons why programming skills are required in automated testing. It is one of the constraints for manual and non-technical testers when executing automated testing.
- Managing tests
Not only is scripting challenging, but so is managing tests if you are a manual or non-technical tester. Why do you have to control tests? If you don’t manage your tests and scripts, many things can occur. First, the effort is duplicated because many people can build the same test scripts. Second, test scripts are created for a single purpose and cannot be reused. Existing automated test scripts are at risk of corruption if they are modified without the knowledge of the original author, and many other things.
Every tool has a standard for reporting the test results. However, sometimes these generic reports do not fulfill your needs. It is challenging to customize the report because it requires a great deal of effort, good planning, and maintenance.
In order to crack all these challenges, in this article, I will not only show you how to create a test case and execute automated tests in three easy steps, but also the solution to manage tests and reports efficiently.
3. 3 Magical Steps to Execute Automated Web Testing
All magicians need supporting tools, and so does web testing execution. My magical trick will be performed with a tool called Katalon Recorder that can be installed in 3 seconds on both Chrome and Firefox's latest versions.
A few words about Katalon Recorder: it has been hailed as one of the alternative solutions since Selenium IDE no longer works from Firefox 55 onwards (read the official announcement). As the toolmakers stated, “Katalon Automation Recorder records actions and captures web elements on web applications to let you generate, edit, and execute automated test cases quickly and easily without programming knowledge requirements.”
And yes, Katalon Recorder is not the only one; there are the same solutions out there, such as Protractor, Kantu, or Robot framework, but I will just show the easiest way and the most proficient tool to do the magical things.
Let's use a sample test case whose scenario is as follows. Imagine you have a service booking site that requires the user to log in, fill in a form, and submit it to accomplish the booking process. After changing a little bit in the theme, you may wonder whether this function is still working or not. The 3 easy steps below will help you get rid of the confusion.
Step 1: Create a New Test Case Using the Record Function
- Click “New” to create a new test case
- Click “Record” to generate a test case with the following steps:
- Access http://demoaut.katalon.com/profile.php#login (the Katalon demo AUT website)
- Enter username/password (John Doe/ThisIsNotAPassword)
- Fill in and submit the form
- Log out
Step 2: Keep Calm and Execute Automated Testing
Click “Play” to run the test and monitor the test case. If the test case fails somewhere, you can stop the playback and remove the bug right there.
You can change the “Value” input manually to test the function with more accounts.
A happy case should be shown as in the image below:
It will bring you back to the homepage without logging into any account.
Step 3: Advanced Steps for Automated Test Experts
If you want to use more variable test data to cover different cases and run the test with these data automatically, Katalon Recorder supports data-driven testing, which allows users to define data sets and execute test scripts that use these data.
- You should download the sample test data here and add the file named “test data.csv” in the “Test Data” tab.
- Import the test cases that are saved as an HTML file by clicking on “Open test suite” instead of clicking on “Create test suite” and open my sample test case.
- Click “Play” to execute the test automatically with the variable input.
That is not all; the Katalon platform also offers a tool called Katalon Analytics, to help you save all the test reports and display them visually through colorful charts. You can upload your results directly to Katalon Recorder by clicking “Upload logs” (the cloud icon). You may be required for sign up a Katalon account at www.katalon.com (for free) and log into Katalon Analytics at https://analytics.katalon.com to create a new project.
Then, come back to the Katalon Recorder window and choose the project for which you want to upload the logs, and click “Upload”
Although Katalon Analytics is launched as the beta version, it meets all my demands for test reports, even shares the results with teammates easily.
4. Run Selenese (Selenium IDE) Scripts on Chrome and Firefox
This is the corner for Selenium IDE fans who are depressed and disappointed after the official announcement of the end of Selenium IDE from Firefox 55 onwards. Some guys at Katalon seems to be bringing the hope back by allowing users to import Selenese scripts from Selenium IDE to Katalon Recorder. Check it out here.
I will say no more about Katalon platform in this post, even it is great and free - it should belong to another post that may be named “How to leverage Katalon platform (Katalon Studio, Katalon Docker, Katalon Analytics, Katalon Recorder) to make your testing life easier.”
Executing automated test cases and managing test reports is not as painful as we thought. In general, with a wise testing strategy and a proper supporting tool collection, test execution or automated testing is no longer a big deal.
Opinions expressed by DZone contributors are their own.