FAIR Consulting Group Containerised Performance test suite - FAIR Consulting Group

Containerised Performance test suite

Share on facebook
Share on twitter
Share on linkedin

Containerised Performance test suite

Docker, a container-based technology is dominating the IT world, especially in continuous integration. 

With this increasing number of organisations and people with DevOps and QA interest are finding ways to transform their skills and get full use of Docker container technology. Docker is very popular in today’s era where revolutionised development is encouraged. Following the market trend, many industry giants have already adopted Docker in their services.

Let’s talk about what Docker means in QA and testing. As a QA, you might have heard Developers and Ops rave about the world of difference Docker makes when building applications and perhaps they are right when it comes to deploying code to a local container, making an image and sharing it with the team. However, QA is still not convinced on why Docker matters to them as most of the implementations are Dev only.

Docker is not just restricted to development. For QA, Docker solves the classic hurdle of ensuring you test the same application on different environments as all the prerequisites are packed in the container and can run consistently. Another problem which I faced was to replicate a performance test script on another environment that was unable to run perfectly. Being a QA, I thought if Docker is not limited to Devs then let’s see what other benefits Docker can give in the testing world.

Containers pack a lot more applications or versions of an application than VMs. This makes them ideal for load and performance testing and their nature of being easily replicable is a plus. Taurus came to the rescue when a pre-built docker image was available on docker hub.

Why do we need Taurus?

Everything you need to run your performance test script sits within a simple container image. We can copy it and share it with our team, thus eliminating the installation of JMeter and its prerequisites on the system we want our test scripts to run. Taurus, on the other hand, provides us a clear reporting of run time processes with its dashboard and provides us with useful KPIs (Throughput per/s of virtual users and health of load-generating machine). The best part is that you can run your scripts written in YAML as well.

So, let’s move on to using Taurus and JMeter in our Docker image. You can find the installation guide here:

After installation and configuration, you just have to run the command

sudo docker run -it --rm -v $PWD/tmp/my-test:/bzt-configs blazemeter/taurus scriptName.yml

for the test script to run.

Summary

Versioned images simplify deployments and are easy to use in CI as well. Taurus and JMeter both are open source and here are used as command line automation tools. My next step would be to containerise Selenium, Postman and other monitoring and testing tools to create a complete test suite being run on Docker.

Stay up-to-date with FAIR

Connect with FAIR today and get the latest tips and tricks on improving your customer experience tools and eCommerce platforms. Once you subscribe you will get access to workshops, webinars, recent projects and so much more.