Test Automation
What is test automation?
There are two kinds of testing in the software, manual and automated. Test Automation is a software testing technique that performs using special automated testing software tools to execute a test case suite. Successive development cycles will require execution of same test suite repeatedly. Using a test automation tool, it’s possible to record this test suite and re-play it as required. Once the test suite is automated, no human intervention is required. Test automation helps to reduce the effort required for adequate testing and increase the testing which can be done in limited time.
Why Test Automation?
It is the best way to increase the effectiveness, test coverage, and execution speed in software testing. Automated software testing is important due to the following reasons:
- Manual Testing of all workflows, all fields, all negative scenarios is time and money consuming
- It is difficult to test for multilingual sites manually
- Test Automation does not require Human intervention.
- Test Automation increases the speed of test execution
- Automation helps increase Test Coverage
- Manual Testing can become boring and hence error-prone.
Automated testing advantages & disadvantages
advantages
- Costs and efficiency
- Time economy
- Quality
- Reusable
- Development team can contribute
disadvantages
- Need better tools and training
- False sense of quality
- A lot of testing areas left uncovered
- Lack of experience
- Lack of clear goals
Automated Test Life-Cycle Methodology
The implementation of automation testing life cycle executes in parallel with the software development life cycle process.
The structured automation testing life cycle comprises of a multi-stage process that supports the activities required to utilize and introduce an automated test tool, develop and run test cases, develop test design, build and handle test data and environment.
In automation testing life cycle methodology, test design is constructed to portray test efforts, to give project and test team a framework on the scope of the test program.
- Determining The Scope Of Test Automation
- Selecting The Right Tool For Automation
- Test Plan + Test Design + Test Strategy
- Setting Up The Test Environment
- Automation Test Script Development + Execution
- Analysis + Generation Of Test Reports
Determining The Scope Of Test Automation
It aims to identify the feasibility of automation. Every aspect should be considered while analyzing the feasibility.
Also, it is essential to perform a feasibility analysis on the manual test case pack that allows automation engineers to design the test scripts.
In this particular stage, the following things should be taken care of without a failure.
- Which modules of the applications can be automated and which not?
- Which test can be automated and how to automate them?
- Factors like cost, team size and expertise should also be considered.
Following feasibility checks should be done before starting the test automation:
- Test Case Automation Feasibility
- AUT Automation Feasibility
Navigate through the application screens under test and mention all UI components of the application to perform feasibility analysis in an effective way. Identify a percentage of UI components to be automated via an automation testing tool.
Selecting The Right Tool For Automation
Automation testing is highly dependent on the tool used. The developers need to consider budgetary constraints, the familiarity of the team with the automation tool used, along with resources available with the team. The choice of the automation tool also depends upon the flexibility and intuitiveness of the team using the tool. The test engineer should define and evaluate the criteria for a pilot test for the automation tool. Testing personnel should then evaluate it based on the different criteria stipulated by the test engineer.
Test Plan + Test Design + Test Strategy
It is the most critical phase of automation testing life cycle methodology that defines how to approach and accomplish the goal of test automation. It involves setting up a test automation framework.
During the test planning phase, the testing team decides the test procedure creation standards and guidelines, hardware, software and network to support test environment, a preliminary test schedule, test data requirements, defect tracking procedure and associated tracking tool and a procedure to control test configuration and staging environments.
The team of test engineers develops a test architecture to describe the test program structure and the way test procedures are managed after the test program model is designed. Post designing comes the test architecture where the structure of the entire test program is described along with the management of test procedure.
Test Management Strategy:
- All manual test cases should be gathered from the test management tool and identifying the test case which needs to be automated.
- The pros and cons of the testing tool should be identified along with the framework for the test.
- The associated risks, background information and dependencies between replication and the tool should be mentioned in the test plan
- A test suite for the automation test case should be built in the tool for test management.
- Approval must be sought for the testing strategy from stakeholders or clients.
Setting Up The Test Environment
The testing team needs to track and schedule the test environment, set up and install test environment software as well as link network resources and hardware.
Key Areas For Test Environment Setup
- Test data — Many times test environment setup are not populated with similar data with comparison to Production, this makes your product very brittle once the code changes are put into production environment
- Front-End Running Environment — Make sure your have a front-end running environment to perform load testing for analyzing the capability of handling web traffic.
- Checklist of all the Systems, modules and applications to be put under test.
- An isolated Database server for staging environment.
- Test across various client operating systems.
- Test across maximum browsers and browser versions.
- Make sure you test your website on low and high network to realize the difference between rendering time and overall appearance of the website or web-app.
- Documentation is key — Make sure you cover all the Configuration guides/Installation guides/User manuals and so on in a central repository.
Test environment setup involves the following tasks:
- Tool licenses.
- Setup utilities like advanced text editors and comparison tools.
- Automation framework implementation
- AUT access and valid credentials
- Add-ins licenses
The best method is to copy production data to the test environment so that the test engineer can find problems without corrupting the product data.
Automation Test Script Development + Execution
Once you install the test environment, it is the time to execute the test script. So, this phase of automation testing life cycle is dedicated to the execution of all test scripts. To perform script execution, signed-off and unit-tested test scripts are delivered to automation testing team.
It is essential to ensure that all test scripts are running correctly. So, there is a need to take care of the following things before developing a test script:
- The test Scripts should be created based on actual requirements.
- A common function method must be created, to be used throughout the test process.
- A structured reusable script must be created so that other team members can easily understand it.
- The codes should be reviewed for test scripts for proper quality assurance.
After the Test Script is successfully Developed the following Processes must be followed:
- A test script should include all functional aspects according to the test case.
- Ensure to run test scripts in multiple environments and across multiple platforms.
- If possible, batch execution can be done to save time and efforts.
- If the failure occurs due to some functionality, write a bug report.
Analysis + Generation Of Test Reports
After all types of testing are performed, the testing team analyzes to identify particular functionality or components that experience a relative number of problem reports. Analysis indicates any requirements for additional tests or procedures. Analysis of test results can confirm if the test scripts or procedures executed have errors or not. This is the end phase of the automation testing life cycle and all test reports must be shared with clients or stakeholders at this stage.
Automation Tools
- LambdaTest
- TestComplete
- QMetry Automation Studio
- TestProject
- Katalon Studio
- Testsigma
- Qualibrate
- Worksoft
- ZeuZ Test Automation Framework
- 21 — Connecting Testing And Production Autonomously
- Testimony
- Selenium
- Subject7
- Appium
- Micro Focus UFT
- Test Studio
- Ranorex
- IBM Rational Functional Tester
Selenium
At present, Selenium is the most popular and widely used tool in the market. This open-source web automation tool is primarily used for web applications. The testing framework of Selenium performs across various browsers and platforms like Linux, Mac, Windows, Firefox, Chrome, IE, as well as Headless Browsers. With a browser add-on Selenium IDE, the tool can record and playback, which means a tester can use these features even with learning Selenium IDE. The powerful Selenium WebDriver helps to create more complex and advanced automation scripts. Also, testers can write in various programming languages like Java, Perl, JavaScript, PHP, Python, C#, Ruby, and Groovy.