SANITY TESTING

What is Sanity Testing?

Sanity Testing is a narrow and focused type of software testing performed to verify that a specific bug fix, minor change, or small feature update works correctly — without doing detailed or full testing.

Narrow and Deep Testing

Surface-Level Testing

Tester’s Sanity Check

Sanity Testing is a quick testing process performed after minor changes or bug fixes to ensure the changes work correctly before proceeding with further testing.

Definition

Sanity Testing is a quick, non-exhaustive test performed after recent code changes to ensure the changes work correctly and have not introduced major defects before proceeding with further testing.

 

 It is a subset of Regression Testing, but with a smaller and limited scope.

PURPOSE

Verify Recent Fixes

Ensures that bug fixes or small updates work as expected.

 

Quick Validation

Saves time by avoiding full regression testing for minor changes.

Prevent Major Failures

Checks whether a small change has broken any critical functionality.

Decide Whether to Proceed

Helps QA decide if the build is stable enough to continue with full regression testing.

When is Sanity Testing Done?

Sanity Testing acts as a checkpoint in the Software Development Life Cycle (SDLC).

It is performed:

  • ✅ After a bug fix

  • ✅ After a minor update or small feature addition

  • ✅ Before starting deep regression testing

  • ✅ In Agile or DevOps environments where frequent builds are released

Advantages

Saves Time
Only the affected functionality is tested, so testing is completed quickly.

Cost Effective
Avoids unnecessary full regression testing for minor changes.

Early Detection of Major Issues
Identifies if a small change has broken critical functionality.

Build Validation
Helps decide whether the build is stable enough for further testing.

Improves Productivity
Testers focus only on relevant areas instead of retesting the whole application.

Limited Coverage
Only specific areas are tested — other defects may remain unnoticed.

Not Detailed Testing
It is not exhaustive, so deeper issues might not be detected.

Risk of Missing Side Effects
Small changes can affect other modules, but sanity testing may not check them.

No Documentation (Sometimes)
Often performed quickly without detailed test cases.

Disadvantages

Difference Between Smoke Testing and Sanity Testing

Feature Smoke Testing Sanity Testing
Purpose To check if the entire build is stable To check if a specific change works correctly
Scope Broad Narrow
When Performed After receiving a new build After bug fixes or minor changes
Depth Shallow and wide Narrow and focused
Objective Verify critical functionalities Verify specific functionality
If Failed Build is rejected Build may go back for fixing

Example

Banking Application

  • A bug was reported: “Login button not working.”

  • Developer fixes the issue and gives a new build.

  • Tester checks:

    • Login works correctly.

    • User is redirected to dashboard.

    • No error message appears.

If everything works fine → Proceed to full testing.
If major issues appear → Build is rejected.

Example

Developer fixes a bug in the payment gateway.
Tester checks:

  • Payment is processed correctly

  • Confirmation message appears

  • Receipt is generated

Only the affected area is tested.

SANITY TESTING

By Content ITV

SANITY TESTING

  • 10