CHAPTER 03
Intermediate
Types of Software Testing
Updated: May 16, 2026
20 min read
# CHAPTER 3
Types of Software Testing
1. Introduction
Software testing is a massive domain. Validating that a user can log in is a completely different discipline than validating that the server won't crash when 10,000 users log in simultaneously. To manage this complexity, the software testing industry categorizes tests into specific types based on their objective. In this chapter, we will demystify the Types of Software Testing. We will establish the primary divide between Functional and Non-Functional testing, and explore critical deployment tests like Smoke, Sanity, and the ever-important Regression testing.2. Learning Objectives
By the end of this chapter, you will be able to:- Distinguish between Functional and Non-Functional Testing.
- Understand the critical role of Regression Testing in agile environments.
- Differentiate between Smoke Testing and Sanity Testing.
- Identify when to apply White-Box vs. Black-Box testing methodologies.
- Categorize tests based on the SDLC phase (Unit, Integration, System, UAT).
3. The Big Divide: Functional vs. Non-Functional
All testing falls into one of these two macro-categories:- Functional Testing (What it does): Validates the software against business requirements. If the user clicks "Add to Cart", does the item appear in the cart? This includes Unit testing, Integration testing, and UI testing.
- Non-Functional Testing (How well it does it): Validates the performance, usability, and security of the application. The cart works, but does it take 15 seconds to load? Does it crash under heavy load? Can a hacker manipulate the cart price?
4. Regression Testing
The Problem: A developer fixes a bug in the "Checkout" module. However, the code they changed accidentally breaks the "Apply Promo Code" module, which was previously working perfectly.- Regression Testing: Re-running previously executed test cases on a new build to ensure that recent code changes have not introduced new bugs into existing, working functionality.
- *Note:* Because this requires running hundreds of tests repeatedly, Regression Testing is the primary target for Automation.
5. Smoke Testing vs. Sanity Testing
When a new build of software is delivered to the QA team, they do not immediately run all 500 test cases. They do preliminary checks.- Smoke Testing (Build Verification): A shallow, broad test. Does the app start? Can I log in? Can I access the main dashboard? If the app crashes on the login screen, QA rejects the build immediately without further testing. It checks the *critical path*.
- Sanity Testing: A deep, narrow test. If a developer specifically fixed the "PDF Export" feature, QA performs a Sanity Test *only* on the PDF export feature to verify the bug is actually fixed before running the full suite.
6. Black-Box vs. White-Box Testing
These are methodologies, not specific phases.- Black-Box Testing: The tester knows nothing about the internal code. They test the application entirely through the User Interface or API inputs/outputs. (Focus: User Perspective).
- White-Box Testing: The tester has access to the source code and database architecture. They write tests based on the internal logic and code paths. (Focus: Developer/Architecture Perspective, mostly Unit Testing).
7. Visual Learning: Testing Hierarchy
txt
8. Best Practices
- Automate Regression: Manual regression testing is soul-crushing and prone to human error. If a test must be run every single time the code changes, it must be automated using tools like Selenium or Cypress.
9. Common Mistakes
- Ignoring Non-Functional Testing: Many teams launch products that pass all Functional tests, only to have the product crash on launch day because they never performed Load Testing. "It works on my machine" does not mean it works for 10,000 concurrent users.
10. Mini Project: Categorize the Test
Scenario: Read the following testing scenarios and categorize them as Functional or Non-Functional.- 1. Verifying that a password must contain a special character. *(Answer: Functional)*
- 2. Verifying that the login page loads in under 2 seconds. *(Answer: Non-Functional - Performance)*
- 3. Verifying that a user cannot access the database via SQL Injection. *(Answer: Non-Functional - Security)*
- 4. Verifying that the "Forgot Password" email contains a valid reset link. *(Answer: Functional)*
11. Practice Exercises
- 1. Explain the "Smoke Test". Why is it called a "Build Verification Test", and why does QA run it before any other test?
- 2. Differentiate between Black-Box and White-Box testing methodologies.
12. MCQs with Answers
Question 1
A developer adds a new feature to an e-commerce application. The QA team runs tests on the older, existing features to ensure the new code didn't break anything that was already working. What type of testing is this?
Question 2
Which of the following is an example of Non-Functional Testing?
13. Interview Questions
- Q: Explain the difference between Smoke Testing and Sanity Testing. When would you execute a Sanity Test instead of a Smoke Test?
- Q: "We have 100% functional test coverage, so our application is ready for production." Challenge this statement. What critical testing types are being ignored?
- Q: Why is Regression Testing the ideal candidate for Test Automation? What happens if a team relies entirely on manual Regression Testing?