KEMBAR78
Software Testing and Types | PDF | Software Testing | Software
0% found this document useful (0 votes)
19 views8 pages

Software Testing and Types

The document provides an overview of software testing, defining its purpose, importance, and types, including manual and automated testing, functional and non-functional testing. It outlines various testing levels in the software development lifecycle (SDLC), real-world examples, best practices, and test case creation methodologies. The conclusion emphasizes the significance of a well-planned testing strategy to enhance software quality and reduce costs.

Uploaded by

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

Software Testing and Types

The document provides an overview of software testing, defining its purpose, importance, and types, including manual and automated testing, functional and non-functional testing. It outlines various testing levels in the software development lifecycle (SDLC), real-world examples, best practices, and test case creation methodologies. The conclusion emphasizes the significance of a well-planned testing strategy to enhance software quality and reduce costs.

Uploaded by

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

1.

Introduction to Software Testing

Software Testing is a critical phase in the software development lifecycle (SDLC) that ensures the
software meets quality standards, functions as expected, and is free from defects.

1.1 Definition of Software Testing

 IEEE Definition: "The process of analyzing a software item to detect the differences
between existing and required conditions (defects/errors/bugs) and to evaluate the
features of the software item."

 Objective: To identify defects, ensure reliability, improve performance, and validate


compliance with requirements.

1.2 Importance of Software Testing

 Ensures software works as intended.

 Reduces development costs by detecting bugs early.

 Enhances security and performance.

 Improves user experience and customer satisfaction.

2. Types of Software Testing

Software Testing can be broadly classified into Manual Testing and Automated Testing. It is
further categorized into Functional and Non-Functional Testing.

2.1 Manual Testing vs. Automated Testing

Aspect Manual Testing Automated Testing

Execution Done manually by testers Done using scripts/tools

Speed Slow Fast

Accuracy Prone to human errors Highly accurate

Best For Exploratory, Usability, Ad-hoc Testing Regression, Performance, Load Testing

Examples Checking UI alignment Selenium, JUnit


Aspect Manual Testing Automated Testing

2.2 Functional Testing (Validates Software Functionality)

Functional testing ensures that the software works according to specified requirements.

a) Unit Testing

 Definition: Testing individual components (functions, methods, classes) in isolation.

 Example: Testing a login function in Python.

b) Integration Testing

 Definition: Testing interactions between integrated modules.

 Approaches:

o Top-down: Higher-level modules tested first (stubs used for lower modules).

o Bottom-up: Lower-level modules tested first (drivers used for higher modules).

 Example: Testing if a payment gateway integrates correctly with an e-commerce cart.

 Tools: Postman (API testing), TestNG.

c) System Testing

 Definition: Testing the complete system against requirements.

 Example: Testing an entire banking application (login, transactions, reports).

 Types:

o End-to-End (E2E) Testing: Testing the full workflow (e.g., user registration → login
→ checkout).

o Smoke Testing: Basic "sanity check" to see if the build is stable.

o Regression Testing: Re-testing after changes to ensure no new bugs are


introduced.
d) Acceptance Testing

 Definition: Final testing to ensure software meets business requirements.

 Types:

o User Acceptance Testing (UAT): Performed by end-users.

o Alpha Testing: Done by internal teams before release.

o Beta Testing: Done by real users in a live environment.

 Example: A company tests a new HR management system before full deployment.

2.3 Non-Functional Testing (Validates Performance & Usability)

Non-functional testing checks how well the system performs under different conditions.

a) Performance Testing

 Definition: Evaluates speed, responsiveness, and stability under workload.

 Types:

o Load Testing: Tests behavior under expected user load.

 Example: Simulating 1000 users accessing a website simultaneously.

o Stress Testing: Tests beyond normal operational capacity.

 Example: Handling 10,000 users when the system is designed for 5000.

o Scalability Testing: Checks if the system can scale up/down.

 Tools: JMeter, LoadRunner.

b) Security Testing

 Definition: Identifies vulnerabilities and ensures data protection.

 Examples:

o Penetration Testing: Ethical hacking to find security flaws.

o SQL Injection Testing: Checking if input fields are vulnerable.

 Tools: OWASP ZAP, Burp Suite.

c) Usability Testing

 Definition: Ensures the software is user-friendly.


 Example: Testing if a mobile app’s navigation is intuitive.

 Methods: A/B Testing, Heatmaps.

d) Compatibility Testing

 Definition: Checks software performance across different environments.

 Examples:

o Cross-Browser Testing: Chrome vs. Firefox vs. Safari.

o Mobile Device Testing: iOS vs. Android.

3. Testing Levels in SDLC

Level Description Example

Unit Testing Tests individual components Testing a calculator’s "add" function

Integration
Tests module interactions Testing login + database integration
Testing

End-to-end testing of an e-commerce


System Testing Tests the full system
site

Acceptance Validates business UAT for a hospital management


Testing requirements system

4. Real-World Examples of Testing

1. Amazon (E-commerce)

o Functional Testing: Checkout process, payment gateway.

o Performance Testing: Handling millions of users during Black Friday.

o Security Testing: Preventing credit card fraud.

2. Netflix (Streaming)

o Compatibility Testing: Works on Smart TVs, mobiles, browsers.


o Load Testing: Handling peak-hour streaming traffic.

3. Banking Software (Security)

o Penetration Testing: Preventing unauthorized access.

o Regression Testing: Ensuring updates don’t break existing features.

5. Best Practices in Software Testing

1. Shift-Left Testing: Start testing early in the SDLC.

2. Automate Repetitive Tests: Use Selenium, Appium for regression testing.

3. Prioritize Test Cases: Focus on critical functionalities first.

4. Continuous Testing: Integrate with CI/CD pipelines (Jenkins, GitHub Actions).

5. Bug Tracking: Use JIRA, Bugzilla for defect management.

6. Conclusion

 Software Testing ensures reliability, security, and performance.

 Different types (Functional, Non-Functional) serve different purposes.

 Automation improves efficiency, but manual testing is still essential for UX.

 A well-planned testing strategy reduces costs and enhances quality.

Discussion Questions

1. What is the difference between Smoke Testing and Sanity Testing?

2. Why is Regression Testing important after every update?

3. How does Security Testing prevent data breaches?

(Test Case Creation)

Functional Testing

Test cases are explicitly created to validate software functionality against requirements.

a) Unit Testing

 When? During coding phase

 Created by: Developers

 Example: Test cases for a calculateTax() function with input-output validations.


b) Integration Testing

 When? After unit testing, when modules are combined

 Created by: QA Engineers/Developers

 Example: Test cases to verify API interactions between Payment Gateway and Order
Service.

c) System Testing

 When? After integration, before UAT

 Created by: QA Team

 Example: End-to-end test cases for an e-commerce checkout flow (login → cart →
payment).

d) Acceptance Testing (UAT)

 When? Final phase before release

 Created by: Business Analysts/End-Users

 Example: Test cases validating if a CRM system meets business workflows.

2. Non-Functional Testing (Test Case Creation)

Test cases focus on performance, security, etc., rather than functionality.

a) Performance Testing

 Test Cases: Simulate user load (e.g., "500 concurrent logins").

 Tools: JMeter, LoadRunner.

b) Security Testing

 Test Cases: Validate vulnerabilities (e.g., "SQL injection attempt on login form").

 Tools: OWASP ZAP, Burp Suite.

c) Usability Testing

 Test Cases: User-centric scenarios (e.g., "Can users complete registration in <2 mins?").

3. Specialized Testing (Test Case Creation)

a) Regression Testing

 Reuse/modify existing test cases after code changes.


b) Smoke Testing

 Minimal test cases to verify build stability (e.g., "App launches without crash").

c) Exploratory Testing

 No predefined test cases; ad-hoc based on tester’s intuition.

Key Takeaways:

1. Test cases are created in all structured testing types (functional/non-functional).

2. Exceptions: Exploratory testing uses minimal pre-written cases.

3. Level-specific: Unit (dev), Integration/System (QA), UAT (end-users).

Example Template for a Test Case:

Test Case ID: TC_Login_01

Description: Verify login with valid credentials.

Steps:

1. Enter username = "test_user".

2. Enter password = "Pass@123".

3. Click "Login".

Expected Result: Welcome page is displayed.

Actual Result: [Filled during execution]

Status: Pass/Fail

Why It Matters?
Well-designed test cases ensure systematic validation and reduce defect escape rate.

Example Test Cases:

Write a test case for the following scenario:

Scenario: A user logs into a banking application using their username and password. Upon
successful login, the user should be redirected to their dashboard. If the credentials are
incorrect, an error message should be displayed: 'Invalid Username or Password.'
Test Case ID: TC001

Test Case Title: Validate login functionality for banking application

Preconditions:

The banking application is installed and accessible.

The user has valid login credentials.

Steps to Execute:

1. Open the banking application.

2. Navigate to the login screen.

3. Enter the valid username and password.

4. Click on the "Login" button.

Expected Result(s):

For valid credentials: The user is redirected to the dashboard.

For invalid credentials: An error message is displayed: "Invalid Username or Password."

Actual Result(s): (Optional)

This field will be filled during the actual test execution.

Scenario: A user adds a product to their shopping cart in an e-commerce application. The cart
should display the product name, quantity, and total price, and the "Checkout" button should
be enabled once an item is added.

Question:

Write a test case for the above scenario

You might also like