Introduction to Testing
Understand testing purpose, major testing types, and the end‑to‑end testing lifecycle.
Summary
Read Summary
Flashcards
Save Flashcards
Quiz
Take Quiz
Quick Practice
What does unit testing verify?
1 of 12
Summary
Introduction to Testing
What Testing Is and Why It Matters
Testing is the systematic process of evaluating a product, system, or component to determine whether it meets specified requirements and to identify any defects. In simpler terms, testing asks: "Does this work the way it's supposed to?"
Testing is performed for several important reasons. First, it validates that the system does what it is supposed to do—confirming the design works as intended. Second, testing finds defects early in the development process, which saves time and reduces cost significantly. The earlier you catch a problem, the cheaper it is to fix. Third, testing improves overall quality by providing confidence that the final product is robust and trustworthy. Finally, testing ensures compliance with regulatory or industry standards, such as safety or interoperability requirements, which may be legally required.
Objectives and Benefits
It's important to distinguish between the objectives of testing and its benefits. The primary objective of testing is to confirm that the design works as intended. The secondary objective is to detect errors before the product is released to users. A further objective is to verify that performance and safety criteria are satisfied.
The benefits of testing follow naturally from achieving these objectives. Testing reduces the risk of costly failures after deployment—failures that could harm both users and the company's reputation. Testing helps maintain customer satisfaction by delivering reliable products. And testing supports continuous improvement by revealing areas where the product can be enhanced.
The distinction here is subtle but important: objectives describe what we're trying to accomplish during testing, while benefits describe what we gain from accomplishing those objectives.
Types of Testing
Different types of testing serve different purposes and occur at different stages of development. Understanding when and how to use each type is essential to comprehensive quality assurance.
Unit Testing verifies that individual components, such as functions or classes, work correctly in isolation. This is the most granular level of testing. Unit tests are commonly automated and performed during software development, often by the developers themselves. Because they focus on small, discrete pieces of code, unit tests can be run frequently and quickly.
Integration Testing checks that combined components interact correctly after they have passed unit testing. This is the next level up in scope. While individual units may work perfectly in isolation, problems can arise when components are connected. Integration testing occurs before system-level testing begins, helping to catch interaction problems before they become harder to trace.
System Testing evaluates the complete, integrated product against both functional and non-functional requirements. This is full-scale product testing where the entire system is tested as a whole. Functional requirements describe what the system should do, while non-functional requirements describe how well it should do it (such as speed or reliability).
Acceptance Testing confirms that the product meets the end-user's needs and contractual criteria. This is the final validation step before delivery to the customer. Often, the end user or client participates in acceptance testing to ensure the product truly meets their needs.
Performance and Stress Testing assess system behavior under different load conditions. Performance testing evaluates how the system behaves under normal expected load—what you'd expect during regular use. Stress testing evaluates system behavior under extreme or peak load conditions, pushing the system to its limits. These tests are commonly applied to web services, hardware, and network systems where load capacity matters.
Usability Testing examines how easy and intuitive the product is for users. Rather than testing whether something works, usability testing tests whether users can figure out how to use it effectively. This testing is conducted in user interface and user experience design, as well as for consumer products where user satisfaction is critical.
The progression from unit testing through acceptance testing represents a journey from testing individual pieces to testing the entire system as the customer will experience it.
The Testing Process
Testing follows a structured cycle that repeats throughout development and deployment. Understanding this process helps ensure that testing is systematic and comprehensive.
Test Planning is where it all begins. This phase defines test objectives, scope (what will and won't be tested), resources (who and what tools are needed), and schedule. Careful planning prevents wasted effort later.
Test Design involves writing test cases or scenarios that cover the required functionality. A test case describes the steps to take, the inputs to provide, and the expected outcomes. Well-designed test cases are specific, measurable, and repeatable.
Test Execution runs the tests—either manually by testers or automatically by testing software—and records the outcomes. This is where you actually see whether the system behaves as expected.
Test Evaluation compares actual results with expected results and logs any discrepancies as defects. This is where you determine if the test passed or failed, and if it failed, what the problem is.
Reporting and Iteration summarizes findings, prioritizes which fixes should be addressed first, and guides the repeat of testing as needed. Once defects are fixed, testing cycles back through the process to confirm that fixes work and haven't broken anything else. This cycle continues until the product meets quality standards.
Think of this as a feedback loop: plan → design → execute → evaluate → report → repeat.
Key Concepts That Define Testing
Several important concepts underlie all effective testing practices.
The preventive nature of testing means that testing catches problems early in the development lifecycle, before they become expensive to fix or affect customers. This is why testing begins during development rather than waiting until the end.
The confirmatory nature of testing means that testing verifies that identified issues have been resolved. After a defect is fixed, testing confirms that the fix actually works and that no new problems were introduced.
Clear requirements are essential for creating effective test cases and measuring success. If you don't know what the system is supposed to do, you can't determine whether it's working correctly. Vague or missing requirements make testing ineffective.
Well-written test cases describe the steps, inputs, and expected outcomes for each test. They serve as both instructions for how to perform the test and documentation of what the system should do.
Systematic documentation records test plans, test cases, test results, and defect reports. This documentation serves multiple purposes: it provides evidence of testing, enables reproduction of issues, and supports learning and improvement.
The core testing cycle consists of planning, designing, executing, evaluating, and improving the product through repeated testing. This cycle is not a one-time event but an ongoing process that continues throughout the product's development and often into maintenance.
Flashcards
What does unit testing verify?
That individual components (like functions or classes) work correctly in isolation
What is the primary purpose of integration testing?
To check that combined components interact correctly after unit testing
At what point in the development cycle does integration testing occur?
After unit testing and before system-level testing begins
Against what does system testing evaluate the complete product?
Both functional and non-functional requirements
What does acceptance testing confirm?
That the product meets end-user needs and contractual criteria
When does acceptance testing take place in the delivery timeline?
It is the final validation step before delivery to the customer
How does performance testing differ from stress testing?
Performance testing assesses behavior under normal expected load, while stress testing evaluates behavior under extreme or peak load
What is the focus of usability testing?
How easy and intuitive the product is for users
What is defined during the test planning phase?
Objectives, scope, resources, and schedule
What is the purpose of the test evaluation phase?
To compare actual results with expected results and log discrepancies as defects
What is the role of reporting and iteration in the testing process?
Summarizing findings, prioritizing fixes, and guiding repeated testing
What are the stages of the core testing cycle?
Planning
Designing
Executing
Evaluating
Improving the product through repeated testing
Quiz
Introduction to Testing Quiz Question 1: Why is testing considered preventive?
- Because it catches problems early in the development lifecycle. (correct)
- Because it verifies that identified issues have been resolved.
- Because it ensures compliance with regulatory standards.
- Because it measures system behavior under extreme load conditions.
Introduction to Testing Quiz Question 2: What does testing validate about a system?
- That it performs its intended functions (correct)
- That it runs faster than competing products
- That it has the most attractive user interface
- That it stays within the project budget
Introduction to Testing Quiz Question 3: What is the primary focus of integration testing?
- Verifying interactions between combined components (correct)
- Checking individual component logic in isolation
- Ensuring the final product meets user acceptance criteria
- Assessing system performance under peak load
Why is testing considered preventive?
1 of 3
Key Concepts
Testing Types
Software testing
Unit testing
Integration testing
System testing
Acceptance testing
Performance testing
Stress testing
Usability testing
Testing Documentation
Test plan
Test case
Definitions
Software testing
The systematic process of evaluating a product or system to ensure it meets specified requirements and to identify defects.
Unit testing
Testing individual components or functions in isolation, often automated during development.
Integration testing
Testing combined components to verify they work together correctly after unit testing.
System testing
Testing the complete integrated system against both functional and non‑functional requirements.
Acceptance testing
Formal testing to confirm a product meets end‑user needs and contractual criteria before delivery.
Performance testing
Assessing how a system behaves under expected load conditions.
Stress testing
Evaluating system behavior under extreme or peak load conditions.
Usability testing
Examining how easy and intuitive a product is for users, focusing on user experience.
Test plan
A document that defines test objectives, scope, resources, schedule, and approach before test case creation.
Test case
A set of conditions, inputs, and expected results used to verify a specific aspect of a system.