Useful steps to take when tweaking test automation processes

    7249
    SHARE
    test automation

    DevOps is one of the buzzing words in the software development and delivery industry. Everyone talks about DevOps and has put these words into action in most of the development and product delivery organisations. To put it short, DevOps is a set of practices that we will undertake to minimise the time taken to develop a change and deliver it to the final customer with high quality.

    DevOps goes hand in hand with other well-known practices such as agile and continuous delivery. The need for DevOps arose from the increasing success of agile software development, as that led to organisations wanting to release their software faster and more frequently. DevOps and continuous delivery share a common background in agile methods and lean thinking: small and frequent changes with focused value to the end customer.

    To facilitate DevOps we use automated tools for each and every part of the product development stages (code, build, test, package, release, configure and monitoring).




    To help the DevOps pipeline in an organisation, many software delivery institutions have now embarked on test automation. With proper test automation tools and practices implemented we are able to test and deliver software with high quality. At the same time, there are a lot of repercussion and nightmares that organisations will face when undertaking a wrong test automation strategy.

    Utilise test automation

    We all deliver web solutions to our customers. Facebook, Google, Amazon and Microsoft are some of the leading software giants who deliver web-based solutions to billions of users worldwide. These solutions utilise web services and sometimes microservices architectures. Therefore, we embark first on the development of these web services before putting the final UI touches on the system. To facilitate faster delivery we should first automate the testing of such web services rather than waiting for the UI to be integrated into the delivery feature. We should use more web services test automation tools and test frameworks to extensively test web services and microservices architecture. It is a good practice to have more test coverage on web services rather than with a UI based functional test.

    The more test issues we see at the foundation level more will be better off in the final stages of testing. These tests should look at testing the web service alone, test web services by integrating with other web services, and test against the contracts established. Web service testing can be automated with tools like RestAssured, Kataloon Studio, Postman and Karate. These are well-known tools in the industry. Web service testing should not limit to functional aspects. It should also be used for performance and security aspects. Tools like JMeter, Load UI and TestingWhiz can be used to test the performance of a web service.

    Facilitate continuous delivery

    In DevOps, we emphasise on continuous delivery. To facilitate continuous delivery we use continuous integration. Most of us do wrong when using continuous integration for test automation. We only push UI functional automation suite to the continuous integration. Where our automated regression will have to wait until the delivery of new option with UI. We should move away with such practice. The best way is to push our service level automated test into the continuous integration. This allows maximum leverage of our test automation practice. The automated security test at services level should also move into the CI process, which allows us to identify any security risks at earlier stages of development.

    Use of the ‘behavioral driven development’ (BDD) approach is another area that also helps application development and automated test development. BDD facilitates creating development code as well as automated code, to what is actually required by the customer, thus eliminating any requirements gaps in delivery and also reworking. We should have a practice where we write automation scripts based on the scenarios (features) accepted by the customers. There are so many add-ons we can utilise for our test automation framework to facilitate BDD. Cucumber for Java and JavaScript, RSpec for Ruby and SpecFlow for .net are some of the add-ons that help this integration.

    Codeless testing

    We should have a test automation strategy to automate test quickly to keep in phase with the delivery pipeline. Rather than opting for tools that need extensive automation coding, it’s a good practice that we use tools that needs less coding or simply codeless. This helps us to reduce our effort on test automation and speed up the test process. Codeless test automation also helps non-technical quality assurance teams to get involved in test automation with no background in coding knowledge. If they know how to test, they can automate. To put codeless test automation into practice we can use test automation tools like Leap Test, Testim.io or TestCraft.

    Machine learning and the use of artificial intelligence (AI) is also an area of focus today, as it will help the teams to bring down testing effort and speed up delivery with high quality. The AI-based test tool should be capable to come up with the test scenarios for a feature, with maximum coverage and design the test automation scripts for it, execute when necessary. There are two great AI automation tools available in the industry. Namely, Appvance IQ and Mabl. With Appvance you can create 1500 test cases in just 5 seconds; a dramatic improvement in testing.

    Operating systems

    To enhance our DevOps pipeline and to leverage the maximum of test automation we should also utilise the cloud-based testing solutions. These solutions enable us to test against a wider range of operating systems, mobile devices and even web browsers, which we cannot have in-house due to high investment and maintenance cost. Automated testing in such solutions helps to assure that the application delivered works on different platforms and environments. The solutions can utilise our BrowserStack, CrossBrowser Testing, Sauce Labs and Perfecto Cloud.

    Another way we can help faster testing, and high-quality delivery is to use tools to help manual testers do more in-depth debugging, helping hunt down more hidden bugs. Tools like Postman and Fiddler helps us to debug web services more in a drill down fashion.

    We should also keep in mind that our test automation suite should have the maximum code coverage of the application being tested. There should be more emphasis on code coverage tools like NCover, dotCover, Atlassian Clover and Cobertura. Looking at test automation code coverage helps us to ensure that our test automation code validates most parts of the application.

    DevOps success

    With DevOps, a test automation engineer’s role expands as they perform more of a developer role. They will have to create automated unit tests to test the developer code and they perform a test drive approach. Automated unit testing is another area where test engineers can embark upon. Therefore, the quality engineering team should work on TestNG, Junit, Mockito and Powermock.

    So adding the final points, we need test automation to facilitate DevOps, as it’s a major contributor to DevOps success. So these tweaks that I have highlighted in this article serves a lot of DevOps practitioners around the world to put the ship safely to the sea and start cursing at maximum speeds.

    Written by Senior QA Consultant at Virtusa, Kushan Shalindra Amarasiri