Regression Testing

What is regression testing and why is regression testing needed?

Regression testing is to re-run a set of test cases every time a change is made to the base software code. To make sure the existing functionality is not affected, new functionality behaves as expected and quality of the product is stable when users use the product. Regression testing is either done manually or automated using some tools. In an engineering company most of the time developers develop certain features or fix bugs based on the clients requirements or fix a bug that arises out of testing. Once a bug arises or a feature needs to be implemented it is raised as a ticket by the team leader. There is a complete process of how it is handled usually in the JiRA project management tool. Every ticket has a developer, a tester and a reviewer. The developer develops the fix or feature and puts the ticket in review after he has tested himself once. Now the reviewer checks the piece of code and ensures he is happy with the changes done by the developer. And puts it in review done state. Finally the piece of code will be merged to the baseline code but not in the production version of the software. This is when the testing team picks this piece of binary image for regression testing. They first perform all functional and non functional test cases that were working before in the previous version of the software. On top of that they also test the new feature by making new test cases that satisfy the new feature if any or test the bug that arises previously. In both cases regression testing is to make sure that hardware quality is maintained every change there is change in software.

Regression testing involves the following stages.

  • Retest all cases functional and non functional.
  • Testing new test cases added as per the features implemented.
  • Prioritising test cases as per the software versions.
  • Added new functional and non functional test cases.
  • Generating and maintaining test case reports.

In some cases only a part of the software needs to be tested. Hence we can categorize as.

  • Unit testing.
  • Functional testing.

Unit testing is usually performed only on a certain part of the software. Like features, subroutines, functions and methods.

Functional testing is usually performed on the complete software. Functional test cases can be automated using certain scripts using python, the most common scripting language used to write test cases. Functional testing is done to certify quality of a product. And is done on a black box. Functions are tested by feeding inputs and examining the output.

There are different types of functional testing one among them is Regressing testing

  • Smoke testing is usually done to see if critical or basic functionality is working before beginning the regression testing. For example “Does the LCD display”, “Does the camera work”, “Does the wifi show” etc or frequent defects are tested first before the complete testing is carried out.
  • Sanity testing is also a quick test done on a piece of software to see if the result of the subset is worth enough to carry on the further testing. 
  • Regression testing is only done when smoke and sanity tests pass.
  • Usability testing.
Program failure
Debugging
Identify bugs
Fix the bug
Smoke test
Sanity test
Regression test

 

What are the different types of regression testing tools?

As specified earlier testers can automate the test case using scripting languages like python, shell and so on. Or perform a manual testing based on the functionality. Some test cases can also be automated via labview. 

Some of the automation testing tools listed are as below.

  • TestComplete
  • QMetry Automation Studio
  • TestProject
  • Katalon Studio
  • Testsigma
  • LambdaTest
  • Qualibrate
  • Worksoft
  • ZeuZ Test Automation Framework
  • CrossBrowserTesting
  • 21 – Connecting Testing And Production Autonomously
  • Testimony
  • Selenium
  • Subject7
  • Appium
  • Micro Focus UFT
  • Test Studio
  • Ranorex
  • IBM Rational Functional Tester

Although there are many other tools as well. You can also automate your test cases using LabVIEW software. It is special GUI based software for applications that require testing, measurement, reporting and control with rapid access to hardware and data insights. LabVIEW is commonly used for industrial automation, data monitoring, data acquisition, instrumental control and data flow graphical representation.

LabVIEW is a visual programming language that provides a graphical representation of the test case. And test cases are designed by connecting wires graphically along with other components, variables, parameters and blocks. LabVIEW is connected to the real hardware via uart, serial bus, usb in order for the test case to run. If the test case depends on the hardware. 

Difference between automation testing and manual testing.

Automation testing is usually done by running scripts to test certain functionalities, scripts are usually written in scripting languages like perl, shell, python or any other language. The script just runs on a click of a button and records or notes the output of the test case and in some cases script stops to run further test cases when one of the previous test cases encounters a failure.

Advantages of automation testing.

  • Scripts can run automatically and never get bored.
  • Allows you to make your product better quality.
  • Provides faster results.
  • Saves time.
  • Saves resources.
  • Eliminates human error.

Disadvantages of automation testing. 

  • It is not a human visual inspection that is needed sometimes.
  • It can only perform what is specified in the test cases and does not catch any bugs that are out of the test case scripts.
  • Testing tool software can cost higher.

Manual testing is a process of testing a software or hardware by manual work and generating the test report. Manual testing is usually done by experienced testers an example is fingerprint to unlock the phone. In this case it is possible to automate but sometimes it is best tested manually as the cost of automating may be higher and that automation is not human and may or not cover all finger test cases. So an experienced tester would probably test 0% finger to 100% finger and monitor screen locks or unlocks.

Although manual testing many iterations to find a bug in the software or hardware. Sometimes it is the only possible way to do it.

Advantages of manual testing.

  • Accuracy.
  • No programming needed.
  • Exact visual inspection as needed.
  • Minor bugs can easily be traced by experienced testers.

Disadvantages of manual testing.

  • Human error is possible.
  • More time and resources.

Sample test case template and important fields of the template.

Test Case FieldDescription 
Test case ID: 
  • Each test case should be represented by a unique ID. To indicate test types follow some convention like “TC_UI_1” indicating “User Interface Test Case#1.”
Test Priority:

  • It is useful while executing the test.

    • Low
    • Medium
    • High
Name of the Module
  • Determine the name of the main module or submodule being tested
Test Designed by
  • Tester’s Name
Date of test designed
  • Date when test was designed
Test Executed by
  • Who executed the test- tester
Date of the Test Execution
  • Date when test needs to be executed
Name or Test Title
  • Title of the test case
Description/Summary of Test
  • Determine the summary or test purpose in brief
Pre-condition
  • Any requirement that needs to be done before execution of this test case. To execute this test case list all pre-conditions
Dependencies
  • Determine any dependencies on test requirements or other test cases
Test Steps
  • Mention all the test steps in detail and write in the order in which it requires to be executed. While writing test steps ensure that you provide as much detail as you can
Test Data
  • Use of test data as an input for the test case. Deliver different data sets with precise values to be used as an input
Expected Results
  • Mention the expected result including error or message that should appear on screen
Post-Condition
  • What would be the state of the system after running the test case?
Actual Result
  • After test execution, actual test result should be filled
Status (Fail/Pass):
  • Mark this field as failed, if actual result is not as per the estimated result
Notes
  • If there are some special conditions which are left in the above field.