A platform built around you

We made sure we have a module for every part of your ServiceNow release process.

View all modules

7 common pitfalls of test automation and how to avoid them

4 min read

November 2, 2023

Paul Chorley

We can all agree that test automation is an essential aspect of software development, helping teams achieve faster feedback, improved efficiency, and enhanced product quality. However, the journey towards successful test automation is challenging. To help you get started, AutomatePro’s very own CEO and Co-Founder, Paul Chorley, has summarised his Kyenote speech that was delivered in front of 400 test experts from across Europe. Chorley unravels the 7 most common test automation pitfalls and how to overcome them.

Pitfall 1 – Lack of Strategy and Planning 

Sometimes, the reason test automation fails is simply because of an underestimation of the time and effort required. Resulting in the project being deprioritised or, even worse, stopped before completion.

Pitfall 1 - Lack of Strategy and Planning

To mitigate this problem, it is essential to get buy-in from key stakeholders, i.e. the Chief Information Officer and IT Director. Having senior-level endorsement is critical to assuring that you have adequate resources and to position test automation as a strategic project. That will help the organisation achieve its overarching objectives.

Pitfall 2 – Poor Tool Selection 

There is a plethora of Test Automation tools available to customers, but they aren’t always as transformational as they appear. Customers should avoid purchasing a solution that falls into these categories.

Pitfall 2 - Poor Tool Selection

  • The free option – The age-old saying, ‘nothing comes free,’ echoes true for test automation tools. Due to the DIY nature of  ‘free’ options such as Selenium, organisations invest immense amounts of time and effort to build the tool from the ground up, resulting in unexpected costs.
  • One size fits all – The inability of these tools to accommodate the unique needs and requirements of individual organisations renders them unfavourable.
  • Click and record – Click and Record systems are not durable because they only offer a snapshot of how a test should be executed today. However, if the way to perform that specific action changes, the recording is no longer applicable or valuable.
  • Technical skills – Developers have become a scarce and costly resource. To keep overheads low, organisations should avoid tools that require expert capabilities to build and maintain tests.
  • AI hype – There’s a lot of noise about how generative AI can transform testing. But with most vendors offering tools that can automatically create tests, customers must be cautious to select a tool that can deliver on its promises.

Pitfall 3 – Lack of scalability 

Over time, tests grow in complexity, necessitating broader test coverage. As a result, the traditional Test Pyramid advocates for unit tests to be performed in larger quantities than API and UI tests because they are faster and more adaptable to UI changes.

Pitfall 3 - Lack of Scalability

Alternative approaches emphasise balancing out unit, API and UI tests as they are faster and stronger due to the advancements in test automation. However, contemporary perspectives flip the traditional approach by conducting more UI tests. UI tests provide greater value to end users because they are a closer simulation of how the systems will be utilised.

Pitfall 4 – Brittle Tests 

Anyone who’s ever worked in test automation can relate to agonising over brittle tests and their impact when a system change is made. Below are the four main reasons why tests are categorised as brittle.

Pitfall 4 - Brittle Tests

  • Fixed/ poor UI element identifiers – test automation systems must be able to identify the UI element and interact with it. However, the more fixed it is, the more brittle it becomes.
  • Hard-coded data – users must be cautious of systems that embed the data into the test itself.
  • Fixed waits –  adding fixed waits in tests is suboptimal. Instead, intelligent dynamic waits should be leveraged because instead of using a blanket wait time, advanced coding techniques instruct the system on how long to wait before the next action.
  • Pre-conditions – relies on data to be in a particular state before executing the test, making tests brittle and more prone to failure. A solution is ‘cradle to grave tests’; they create the data required to get in the right state before it executes.

Pitfall 5 – poorly designed tests 

There are 6 main problems around poorly designed tests.

Pitfall 5 - Poorly Designed Tests

  • Repetition – the same tests are repeated in many different test scenarios.
  • Wrong users – although it may seem convenient at first, using impersonation during testing can introduce risks and compromise the integrity of test results. Instead, persona user accounts should be used.
  • Poor control – To achieve tight test controls, configuration management is required. It provides information such as the version running, what the latest changes are, who made the change etc.
  • Test size – The size of the test needs to be appropriate for the specific test.
  • Quantity vs quality – It is important to note that the volume of the test is not the objective but rather the quality and how effective the system is at finding defects.
  • Unrealistic tests – Focus should be on building business scenario tests that reflect the end user’s role and activities.

Pitfall 6 – Overlooking test maintenance 

Tests must be maintained to stay in line with the functionality and to sustain the ideal 100% test coverage, which is often unattainable in practice. A dip in test coverage minimises the perceived value, resulting in testers neglecting the entire test automation suite.

Pitfall 6 - Overlooking Test Maintenance

Pitfall 7 – Not Integrated into DevOps lifecycle / CI / CD

The goal of most DevOps /CI/CD initiatives is to increase the speed and reduce the cost of delivery while maintaining quality.

Pitfall 7 - Not Integrated into DevOps/ CI/CD

Customers fall into one of the four quadrants in the diagram above, with the ideal positioning being the DevOps Joy Land. In this quadrant, the DevOps lifecycle is fully automated and integrated, resulting in fast speed and low cost for the organisation.

Are you ready to take your organisation to the next level with the power of test automation? Contact us today to learn how AutomatePro’s suite of Test Automation, DevOps and Documentation tools can transform your business.

Paul Chorley is AutomatePro’s Chief Revenue Officer and Co-Founder, driving the company’s vision to revolutionise test automation and DevOps for ServiceNow. Passionate about creating meaningful impact, Paul is dedicated to empowering the entire AutomatePro ecosystem; including customers, partners, colleagues and the wider community to live more fulfilling lives.

More blog posts

Curious how AutomatePro can improve your business? Sign up for a free trial.

Sign up