Delivery of a high-quality product and top-notch functionality is the main goal and the top priority of AdTech Holding. How do we achieve it again and again?
The key to success is automation on all development steps from testing to release.
This is how automation helps us to stay time-efficient and keep quality at the highest possible levels:
Automated process | How it helps |
Testing | Allows to perform all necessary tests quickly |
Testing Environment Setup | Saves time on manual environment updates and tests |
Results Delivery | Gives a transparent status of every task to all the involved team members |
However, it wasn’t always like this.
Mikhail Sidelnikov, Lead QA of the AdTech Product Team, shared how the team managed to build smooth automation within five steps — literally from scratch.
Back in 2016, AdTech QA Team wasn’t even close to automation. In fact, the holding was far away from even having well-organized quality insurance processes.
Mikhail Sidelnikov: Deploying a code to production without any elaborate testing was a typical practice. It worked out sometimes — but still implied too many reverted commits, with each of them meaning a potential loss of money.
To change this situation, the QA team came up with a plan for the new efficient process:
This accurate plan launched the beginning of the automation era — and the team began to put it into effect.
The new strategy idea produced five legitimate questions:
A detailed answer to every question became a successful step in automating development and QA processes.
Mikhail Sidelnikov: The first and usually the most challenging question you must ask yourself when trying to build automation is, ‘What should we cover with tests?’
To answer this question, let’s first look at the two main components of the product (in our case, an ad network):
The most efficient way to understand what requires testing is to find out the most popular functionality. In other words, the question can be rephrased, like ‘Which features do customers use most of all?’
How to find the answer to this? There are several options available:
The last one turned out to be the most convenient solution: all requests were accurately collected and tracked, and, thanks to this practice, QA engineers could have immediate feedback on what tests should be run first.
Again, there were several ways how to choose the programming language for building automation. Here they are:
Mikhail Sidelnikov: Many consider this one as having a seemingly big advantage: developers can easily correct and create new tests themselves. However, I suppose it’s not the most reasonable argument. In fact, developers rarely work with QA tests — while QA engineers need to struggle with the language they are not used to.
Mikhail Sidelnikov: It’s much easier to help developers learn how QA tests work — even if they are written in a different language. So, we decided to go this way.
The AdTech Holding QA Team chose JAVA: the whole QA team had vast experience in writing JAVA codes and knew how to create infrastructures for this language. Besides, thanks to frameworks, JAVA has many out-of-the-box features: for example, a very simple and still efficient test parallelization by JUnit.
As a result, the team settled on the following stack:
Mikhail Sidelnikov: This list proved itself to be efficient at all our projects — it works flawlessly, no matter if you have 50, 5000, or more tests.
The overall development system at AdTech Holding consists of many different projects — but all these projects mainly use the same database.
However, there is no need to create a specific integration with a common database for every project. Instead, it’s possible to make a so-called wrapper — a block of code that can be used by multiple teams and their members.
To realize this solution, we implemented Artifactory. It has a very simple integration with Maven:
As a result, every team member can get access to the new version and use it. And all of us can use and maintain these libraries easily.
To be more precise, the question is “What’s the right time to launch tests”?
Mikhail Sidelnikov: There are plenty of options, including nightly regression testing and manual tests at master after release — but this was not the approach we were looking for. What we needed was quick and high-quality CI/CD.
This is how the process was finally organized:
Thanks to this set of practices, we at AdTech Holding have a very fast development process, with up to 50 deployments to production per day. What is important, most of these deployments are not just quick bug fixes — but major tasks.
The main concern of exactly the QA team was the last process — the one related actually to testing — and also its integration into the overall development workflow. The final solution looks the following:
Mikhail Sidelnikov: It doesn’t take much time to run tests so often with this workflow. About 800 tests for one of the services take approximately 7-8 minutes to complete. This time includes creating environments from about 20 Docker containers — and it’s not too long for the full regression testing cycle.
Finally, transparency: one of the key factors of successful automated testing.
In this article, we will highlight the main principles of transparency. You can read more about it and why it is so important in Quality Assurance in this interview.
Transparency implies timely delivery of the status of each test to every process member. And this is how we do it at AdTech Holding:
Stage 1. The status of the test automatically appears on Github. All that was left for the QA team is to set the build feature in Teamcity:
Stage 2. All test results are available at Allure/Allure TestOps: it’s possible to check the status of every component and the whole testing history.
Stage 3. In-house solutions for Slack notifications. Despite having plenty of ready options, AdTech Holding created its own notifications systems working the exact way our teams need. At the moment, they look like this, but we are constantly updating and upgrading them:
Everyone has quick access to test results, links to reports and builds in TeamCity, Pull Request data, and even a button to automatically relaunch builds. All blocks are configurable – if you do not need any – just remove them in the build configuration parameters. And all of this — in a single Slack app.
This article showed that building high-quality, quick, and efficient automation doesn’t require much time and effort. All the processes that we shared in this article prove their effectiveness at AdTech — and we see no reason why they can not be adopted by other businesses.