Test Automation and its importance in the E-Commerce Industry

we.R.play
7 min readMay 11, 2021

By Shaikh Bilal Mohiuddin, Senior QA Engineer at WRP Studios

What is Automation Testing?

We are aware that manual testing is performed by humans executing steps manually. Automation testing, on the other hand, means using a test tool to execute a test suite automatically. In QA, automation testing refers to the use of a separate set of code written to run tests on the software under analysis and compare outcomes of that test against what’s expected of that software.

Now that we have an idea of what automation in QA is, but before we can move on to its advantages; it’s important to keep in mind the following:

“The purpose of automated testing is to reduce the number of test run manually and NOT to eliminate manual testing”

Why Automate?

“We can conduct tests on a wide range of devices. With the right device farm, we can make an automated regression on diverse devices. Doing so manually would probably take hours” — Szymon Sobecki (QA Specialist)

Let’s go back to the 18–19th century when the industrial revolution took place. New manufacturing processes were introduced and we saw a rise in workplace automation. Machines took over all the repetitive and boring tasks. Back then this was required to produce the same parts over and over again which machines could do in less time and thus enhancing productivity.

The same approach has been applied to the software developed these days. During every software development cycle, there is some testing involved. Despite all the testing efforts; a delivered software always has some defects. Test analysts work hard to catch those defects before the software is released. But those defects creep in every time even with the best of manual testing processes. Automation testing is the best way to increase effectiveness, efficiency, and coverage in software testing.

Let’s take a look at the advantages of automation in QA.

1. Increases Test Coverage: Test coverage is a metric in software testing that measures the amount of testing performed. In simpler words, imagine a test suite having 100 test cases in total. When we execute 90 of those test cases, our test coverage would be 90%

An efficiently written test code can run hundreds of tests in a short period of time. This means we can create more tests, more test scenarios, and test with a variety of input data for a feature under test. Doing so will give us confidence in the reliability of our system.

2. Increase in Test Repeatability Saves Time and Money

The aspect of repeatability in automation adds up to several other advantages.

Tests have to be repeated several times during a development cycle. These repeatable tests also called software testing terms Regression Tests are the ones that need to be automated. For every release of the software, multiple cycles of regression testing may be required. Conducting these tests manually every time can be a mundane task increasing the risk of errors.

Automated regression tests are not only reliable but are also less time-consuming than doing the same manually. In SDLC, anything that saves time correlates to saving money. Automated testing has a better Return on Investment (ROI) in the long run even though the initial costs of writing test scripts may seem high.

What to & What NOT to Automate

Based on the above-discussed factors of repeatability, time-saving, and no human intervention in automation testing. We can list the types of test cases we should or should not automate:

✅ — Business Critical cases that involve High Risk

✅ — Cases that need to be performed regularly i.e. Regression testing

✅ — Test cases that are otherwise difficult to perform manually and are time-consuming

❌ — New features/scenarios that haven’t been tested manually

❌ — Test cases for which requirements keep changing

❌ — Tasks that do not require repetitive testing as writing automated test cases is time-consuming and we do not require coding effort for such test cases

E-Commerce Automation

In this digital age, there could hardly be anyone who hasn’t shopped online. Shopping online has its advantages. With easy access to products worldwide, we’re just a few clicks away from ordering almost anything from the comfort of our homes.

Online shopping businesses thrive on their online customers. The competition is increasing with the increasing number of online stores. For an E-Commerce store to survive, businesses need to keep their customers engaged from the very beginning. Otherwise, a customer might end up choosing another website/app to shop from.

The better the website, the better the business will be.

Common Testing Practices in E-Commerce Platforms

With the increasing demand for online shopping; E-Commerce websites require continuous upgrading. E-Commerce platforms are highly dynamic, meaning that the website won’t stay the same for long with new sales/promotions constantly getting updated. All this makes testing an entire website quite overwhelming.

Automated testing for e-commerce websites ensures the quality of the site’s performance under stress and its functions. Following are the 2 most important types of tests that are automated for an e-commerce platform

1. Performance Tests Analytics has shown that 40% of the potential customers abandon the website if the pages take more than 4 seconds to load. A low conversion rate means a loss in business. To prevent this from happening, websites have to be updated with speed improvements.

Such speed tests can be performed using automated tools. Test scripts can be written to simulate the traffic of thousands of users making it possible to assess a website’s speed while under stress.

Amazon’s homepage performance on Desktop on different browsers. Imagine doing this task manually!!!

2. Regression Tests Already emphasized this above; e-commerce websites require continuous testing due to regular changes in sales, promotions, policies, etc.

With automation, we can run regression tests with no human intervention to ensure the quality of the website’s functionality. Considering 70% of the current online shoppers use their mobile phones to place orders. It makes perfect sense to run automated tests on a large variety of devices. These tests can be performed at regular intervals over and over again which otherwise would be a tedious task for manual testers, bringing in a negative impact on a website’s quality.

E-Commerce Automation as a personal experience

For the last 2 years, I have been working with an E-Commerce based client. During the early days of work on this project, I performed manual regression tests on websites of 2 different brands; each website has multiple languages and online stores in 5 different countries. Do the math and it is 20 websites to test. And this count does not include mobile apps.

Performing continuous manual regression tests on these websites was a tedious task often taking multiple days to complete. And I won’t deny the fact that I might have missed out on some minor details knowing I have about 20 websites to test.

About a year ago, a request came from the client I’m working with, to automate these regression tests otherwise run manually. Writing test scripts was a task that took a couple of months to complete. But believe me when I say; the effort was TOTALLY worth it!!

All those manual regression runs that took a few hours have been replaced by parallel automated tests that take under 10 minutes to execute. This has allowed the QA teams to spend more time testing new development features without worrying about running those manual regression tests on existing ones. The tests vary from landing on a website’s homepage, creating a new user account, checking randomly picked products, to placing automated orders hence ensuring we are not facing any downtime on our websites. Any hiccups are automatically reported to the developers using incident management tools like Pager Duty.

Ever since the automation framework has been in place, we have had lesser complaints from customers related to downtime adding value to the business and allowing QA teams to work on other tasks.

Conclusion

Implementation of automated systems often results in positive bottom-line results regarding time and cost-effectiveness. In conclusion to the discussion above, from a tester’s perspective, performance, productivity, cost, and time reduction are powerful arguments for adopting automation.

The most important factor for an e-commerce website is its “Conversion Rate” i.e. the rate of visitors turning into actual customers. Updating an e-commerce website regularly to suit market demands is critical. These regular updates require the need for continuous testing. Incorporating automated tests in e-commerce websites can help maximize their potential.

About Us
WRP Studios is a game development and animation studio making our own games and providing game development services around the world. Our latest ego boost is when Explottens got published by Apple Arcade. It was one of the launch titles to go LIVE in 2019.
Website: https://werplay.com/
Discord: https://discord.gg/jaWhzuy
Jobs: careers@werplay.com

--

--