Regression testing is a testing that is done to verify that a code change in the software does not impact the existing functionality of the product.
This testing makes sure that the product works fine as previously with the newly added functionality or any change in the existing feature or once the bug fix is done. Previously executed test cases are reexecuted in order to verify the impact of change.
- Unit Regression is done during the unit testing phase and code is tested in isolation i.e. any dependencies on the unit to be tested are blocked so that the unit can be tested individually without any discrepancy.
- Partial regression is done to verify that the code works fine even when the changes have been done in the code and that unit is integrated with the unchanged or already existing code.
- Complete Regression testing is done when a change in code is done on a number of modules and also if the change impact of a change in any other module is uncertain. Product as a whole is regressed to check any changes because of the changed code.
Some of the most important tools used for both functional and regression testing in software engineering are-
Rational Functional Tester(RFT)-IBM's RFT is a Java tool used to automate the test cases of software applications. This is primarily used for automating regression test cases and it also integrates with Rational Test Manager.
Quick TestProfessional (QTP) -HP Quick Test Professional is automated software designed to automate functional and regression test cases. It uses VBScript language for automation. It is a Data-driven, Keyword-based tool
Selenium: This is an open source tool used for automating web applications. Selenium can be used for browser-based regression testing.
Configuration Management during Regression Testing becomes essential in Agile Environments where a code is being continuously modified. To ensure effective regression tests, we must observe the following :
- Code being tested should be under a configuration management tool
- No changes must be allowed to the code during the test phase. Regression test code must be kept immune to developer changes.
- The database used for regression testing must be isolated. No database changes must be allowed
We do regression testing by re-executing the tests against the modified application to evaluate whether the modified code breaks anything which was working earlier.Regression testing gives confidence to the developers that there is no broken functionality after modifying the production code. It makes sure that there are no unexpected side effects.
We do execute regression tests in the following cases:
1) When new functionalities are added to the application.
2)When there is a Change Requirement
3)When there is a Defect Fix.
4)When there is a Performance Issue Fix.
There are some testing problems for regression testing
- With successive regression runs, test suites become fairly large. Due to time and budget constraints, the entire regression test suite cannot be executed
- Minimizing the test suite while achieving maximum Test coverage remains a challenge
- Determination of frequency of Regression Tests, i.e., after every modification or every build update or after a bunch of bug fixes, is a challenge