0% found this document useful (0 votes)
16 views

LECTURE 1 STN

The document provides an overview of software testing and quality assurance, emphasizing the importance of detecting defects, ensuring quality, and reducing costs. It distinguishes between software testing, which identifies and fixes defects, and quality assurance, which focuses on preventing defects throughout the software development lifecycle. Additionally, it outlines various testing methodologies, types of testing, and key concepts such as verification and validation.

Uploaded by

Hesham MosaAd
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

LECTURE 1 STN

The document provides an overview of software testing and quality assurance, emphasizing the importance of detecting defects, ensuring quality, and reducing costs. It distinguishes between software testing, which identifies and fixes defects, and quality assurance, which focuses on preventing defects throughout the software development lifecycle. Additionally, it outlines various testing methodologies, types of testing, and key concepts such as verification and validation.

Uploaded by

Hesham MosaAd
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 21

Software Testing and Quality

Assurance
Chapter 1
Basic Concepts and Preliminaries
Introduction to Software Testing
 What is Software Testing?
 Software testing is the process of evaluating a software application to
detect and fix defects before it is released to end users. It ensures
that the software functions as intended and meets the defined
requirements. Testing helps in identifying potential vulnerabilities,
improving software reliability, and ensuring compliance with
specified requirements.
 Software testing can be static (reviewing documentation,
walkthroughs, and code inspections) or dynamic (executing the
code and analyzing its behavior). Both approaches help in enhancing
software quality.
Why is Software Testing Necessary?

 Detecting Defects: Errors or bugs in software can cause failures,


making it crucial to identify and correct them early in development.
 Ensuring Quality: Testing ensures that the software is functional,
secure, and meets performance expectations.
 Reducing Costs: Detecting and fixing defects in earlier stages is
more cost-effective than addressing them post-deployment.
 Enhancing User Experience: A bug-free application enhances
customer satisfaction and trust.
 Compliance with Standards: Many industries (e.g., healthcare,
finance) have regulatory requirements that software must meet.
 Difference Between Testing and Quality
Assurance
software testing is the process of evaluating a software application to
ensure it functions as expected and is free from defects. It focuses on
executing the software under controlled conditions to identify issues
and verify that the system meets the specified requirements.
 Key Aspects of Software Testing:
 Identifies bugs and defects in the system.
 Ensures correct functionality by validating expected outputs.
 Conducted after development to verify the product’s behavior.
 Uses test cases and test scripts to evaluate performance.
What is Quality Assurance (QA)?
Quality Assurance (QA) is a process-oriented approach that
focuses on preventing defects rather than detecting them. It
involves implementing standards, methodologies, and best
practices throughout the software development lifecycle to ensure
high quality.
 Key Aspects of QA:
 Focuses on process improvement to reduce the chance of
defects.
 Implemented throughout the development lifecycle (not
just after coding).
 Ensures compliance with industry standards (ISO, CMMI, Six
Sigma, etc.).
 Uses reviews, audits, and documentation to track quality.
Comparison Between Software Testing and QA

Aspect Software Testing Quality Assurance (QA)


Prevents defects from
Focus Identifies and fixes defects
occurring
When Applied After development Throughout the SDLC
Approach Reactive Proactive
Test cases, execution, Audits, process
Techniques Used
debugging documentation
Software Development Life Cycle (SDLC) vs. Software
Testing Life Cycle (STLC)
What is SDLC?
The Software Development Life Cycle (SDLC) is a structured
process that guides the development of software from concept
to deployment and maintenance. It defines phases to ensure
systematic software creation and high-quality deliverables.
Key Phases of SDLC:
Requirement Gathering & Analysis: Understanding client
needs.
Design: Creating architectural and technical designs.
Implementation (Coding): Writing the source code.
Testing: Verifying the functionality and quality of the software.
Deployment: Releasing the software for user access.
Maintenance: Handling updates and bug fixes.
What is STLC?
 The Software Testing Life Cycle (STLC) is a subset of SDLC that
focuses specifically on testing. It includes various stages that
ensure a structured approach to software validation.
 Key Phases of STLC:
 Requirement Analysis: Understanding test requirements from
SDLC documents.
 Test Planning: Defining test scope, resources, and timelines.
 Test Case Development: Writing test cases and preparing test
data.
 Test Environment Setup: Configuring hardware and software for
execution.
 Test Execution: Running test cases and logging defects.
 Test Closure: Documenting results and analyzing defect trends.
Types of Software Testing
Manual Testing vs. Automated Testing
1) Manual Testing:
 Carried out by human testers without the use of automated tools.
 Best for usability testing, exploratory testing, and test scenarios
that require human judgment.
 Slower and more error-prone but useful for testing new functionality.
2) Automated Testing:
 Uses scripts and tools (e.g., Selenium, JUnit, PyTest) to execute test
cases automatically.
 Best for repetitive tasks, regression testing, and performance
testing.
 Requires an initial setup but saves time in the long run.
Test Scenarios and Test Cases
What is a Test Scenario?
 A test scenario is a high-level description of a feature or
functionality that needs to be verified. It provides a broad view of
what should be tested without delving into specific steps.
Example:
 "Verify that a user can reset their password successfully."
 "Check that a user can add an item to the shopping cart."
What is a Test Case?
 A test case is a detailed step-by-step execution plan designed to
validate a particular functionality. It includes test steps, input
conditions, expected results, and the actual results recorded during
execution.
What Are Software Testing Methodologies?
 What Are Software Testing Methodologies?
Software testing methodologies define structured approaches used to
test software applications. They ensure that the software meets
functional and non-functional requirements before deployment.
 Types of Software Testing Methodologies
 Black-Box Testing:
 Focuses on the system’s inputs and expected outputs without examining
internal code.
 Examples: Functional testing, regression testing.
 White-Box Testing:
 Tests the internal logic and structure of the application’s code.
 Examples: Unit testing, statement coverage, branch coverage.
 Grey-Box Testing:
 A combination of Black-Box and White-Box testing.
 Testers have partial knowledge of the system’s internal workings.
Functional and Non-Functional Testing
Functional Testing
 Ensures that the software meets the defined requirements
and behaves as expected.
 Common functional testing types:
 Unit Testing: Tests individual components of the application.
 Integration Testing: Validates how different modules
interact.
 System Testing: Examines the entire system’s compliance with
specifications.
 User Acceptance Testing (UAT): Conducted by end users
to validate the software before deployment.
Non-Functional Testing
 Focuses on attributes like performance, security, usability,
and scalability.
 Common non-functional testing types:
 Performance Testing: Measures response time, scalability,
and reliability.
 Security Testing: Ensures protection against unauthorized
access and threats.
 Usability Testing: Evaluates the user-friendliness and
experience of the software.
Verification and Validation
These two key concepts in software quality assurance are
defined as:
 Verification: Ensuring that the software correctly
implements specified requirements. It answers the question,
"Are we building the product right?"
 Validation: Ensuring that the software meets user needs and
expectations. It answers the question, "Are we building the
right product?“
Verification techniques include inspections, walkthroughs,
and reviews, while validation is performed through
functional testing, user acceptance testing, and beta
testing.
Failures, Errors, Faults, and Defects
Understanding the distinctions between these terms is crucial
for effective testing:
 Failure: The inability of software to perform a required
function.
 Error: A human mistake that results in incorrect software
behavior.
 Fault (Bug): A defect in the software code or design that
may cause an error.
 Defect: A deviation from expected behavior detected
during testing.
A failure occurs when a defect in the system is triggered
under certain conditions. For instance, a division by zero
error in a calculator application may go unnoticed until a user
inputs zero as a divisor, causing a runtime failure.
Objectives of Testing
The main goals of software testing include:
 Detecting and fixing software defects.
 Evaluating software performance under different
conditions.
 Ensuring that the software meets functional and non-
functional requirements.
 Enhancing software maintainability and scalability.
 Preventing defects rather than just detecting them.
Testing is not just about finding bugs; it also plays a crucial role in
optimizing performance, security, and compliance with industry
standards. Automated testing tools such as Selenium, JUnit, and
LoadRunner help streamline the testing process and improve
efficiency.
Test Levels and Techniques

Software testing is carried out at different levels:


 Unit Testing: Focuses on individual components using
techniques such as white-box testing.
 Integration Testing: Ensures that combined components
interact correctly.
 System Testing: Validates the complete software system.
 Acceptance Testing: Conducted to verify if the system
meets user expectations.
Common testing techniques include:
 Black-Box Testing: Examining system functionality without
knowing the internal code structure.
 White-Box Testing: Analyzing internal code logic.
 Regression Testing: Ensuring that new changes do not break
existing functionality.
 Performance Testing: Evaluating system behavior under load.

You might also like