Test automation can deliver quick results. Provided that you plan it and adhere to the best testing practices and guidelines. Apart from the test automation strategy, you need to know the guidelines which – although they vary as per application type, tools and technology used – can facilitate the automation process. Knowing things in advance and planning the testing ahead can reduce the maintenance effort and make the scripts more usable.
Types of Automated Testing
What are the most commonly used types of automation testing? We are discussing it in this article. Some types of testing are more suited for automation than other so it is handy to know them before you decide on your test automation strategy and the choice of the right testing tool.
Black box vs. white box testing
-
Black box testing means that testing the application does not require knowledge of its internal working or implementation. The phrase “black box” means that the application is like a black box for the tester supplying input and analyzing the output.
-
White box testing (otherwise called “glass box testing”): is the opposite of black box testing. It means that the tester knows the internal workings and the implementation details, such as code, configs, etc. The tester carries on testing paths relying on this knowledge.
Testing pyramid
- Level 1:
- Level 2:
- Level 3:
Test automation frameworks
- Maximum coverage
- Code reusability
- Low-cost maintenance
- Minimal manual intervention
- Recovery scenario
- Easy reporting
Linear Framework (Record and Playback)
This is the most basic testing framework. For each test case, testers write and run a test script. Most of the time, they record and play it back on screen (hence the name). As Linear Framework is very simple, it is mostly recommended for small teams and where test automation has only been introduced recently.
Module (Modular) Based Testing
This approach proposes that the “application under test” (a test case) is divided into smaller parts called modules that are logical, isolated and independent of each other. Then, independent test scripts are created for each of these modules. As the modules are separated by an abstraction layer, any changes that are introduced in the various sections of the application don’t impact the module itself.
Modules of a given scenario are handled by a “master script” which saves testers a lot of time spent on workflow optimization and leads to more cost-efficient maintenance. This framework is also quite scalable. Plus, if the changes are implemented in only one part of the application, only the test script that represents this part of the app needs fixing. However, to successfully implement the Modular Based Framework, testers need to have test automation knowledge and plan the testing ahead. With implementing test scripts separately for each module, data is embedded into the test scrips which means that whenever you need to test with a different set of test data, this requires a lot of manipulations to be made in the test script.
Hybrid Testing: This approach is a combination of some of the others outlined above, mainly data-drive and keyword-driven frameworks. It is sometimes called the ideal automation framework as it leverages the benefits of all associated frameworks. Hybrid Testing allows for more scope of testing, increased productivity and higher efficiency.
Behavior-Driven Development framework
It allows automation of functional validations in a clear, understandable format to business analysts, developers, testers, etc. This framework does not require programming language. For BDD, there are also many different tools available for testing.
Types of testing that can be automated
-
regression tests: they combine functional and non-functional tests to check if the system has not regressed after a change
-
smoke tests: tests to cover the most critical functionalities of a given software solution.
-
integration tests: cover all individual pieces and functionalities of a software solution and test them all together to verify if they co-operate correctly.
-
security tests: these tests cover both functional and non-functional tests and look for any vulnerabilities within the software and reveal any potential exploits in the system
-
performance tests: these are non-functional tests helping testers evaluate certain system criteria (e.g. stability, responsiveness, etc.) and check how the system handles stress and load.
-
acceptance tests: there determine if the software if “acceptable” to the end-users. They are run as a final phase before the software is released.