Unit - 4: Performance Testing of E-commerce Application
Q1. Imagine an e-commerce application which allows users to browse products, add items to
their cart, proceed to checkout, and make purchases. The stakeholders are concerned about the
application’s ability to handle a large number of concurrent users during peak shopping periods
without experiencing performance degradation. Show the testing methods that check the
performance degradation of the e-commerce application.
Answer:
Introduction:
Performance testing is a type of non-functional testing that determines how an application
behaves under various load conditions. It is crucial for applications like e-commerce platforms
that must perform reliably even under high traffic, such as during sales or festivals.
Testing Methods for Performance Degradation
1. Load Testing:
Purpose: To check the system’s ability to handle expected user load.
Scenario: Simulate a typical number of users browsing and purchasing items
concurrently.
Expected Outcome: The system should function smoothly under average peak
conditions without delays or crashes.
2. Stress Testing:
Purpose: To determine the upper limit of the system and how it recovers from failure.
Scenario: Gradually increase the load beyond expected levels to identify breaking points.
Expected Outcome: Application may degrade gracefully, logging errors or refusing
requests once the limit is reached.
3. Spike Testing:
Purpose: To evaluate how the system handles sudden and extreme increases in user load.
Scenario: Introduce a sudden spike in users (e.g., flash sale).
Expected Outcome: Application should absorb the spike or recover quickly after
slowdowns.
4. Endurance (Soak) Testing:
Purpose: To determine performance over an extended period.
Scenario: Run the system under a moderate load for several hours or days.
Expected Outcome: System should not show memory leaks or slowdowns over time.
5. Scalability Testing:
Purpose: To assess the system's ability to scale up (vertically or horizontally).
Scenario: Add resources and observe system performance with increased users.
Expected Outcome: Application should scale proportionally and maintain performance.
Performance Metrics to Monitor
Response Time: Time taken to return results to the user.
Throughput: Number of transactions handled per second.
CPU & Memory Utilization: System resource usage.
Error Rate: Frequency of failures under load.
Concurrent Users: Number of active users the system can support simultaneously.
Conclusion:
Performance testing ensures the reliability and responsiveness of e-commerce applications under
expected and extreme conditions. Conducting these tests can help stakeholders ensure a smooth
shopping experience even during peak events.
Q2. Consider a mobile banking application that allows users to check account balance, transfer
funds, pay bills, and view transaction history. The stakeholders are concerned about ensuring
that the application is compatible with different mobile devices and screen sizes.
(i) Which types of tests would you perform for the application described
above?
For a mobile banking application, the following types of tests are essential:
1. Functional Testing
o To verify that each function of the application works as expected (balance
checking, transfers, bill payment, etc.).
2. Compatibility Testing
o To ensure that the application runs smoothly across various mobile devices
(Android/iOS), OS versions, screen sizes, and resolutions.
3. Performance Testing
o To verify that the app handles load efficiently, such as during peak usage (e.g.,
end-of-month transactions).
4. Usability Testing
o To assess user-friendliness and ease of navigation for all users.
5. Security Testing
o To ensure sensitive data (e.g., account info, transaction details) is encrypted and
secure from threats.
6. Configuration Testing
o To check how the application behaves with different settings like dark mode,
regional settings, language options, etc.
7. Interrupt Testing
o To test app behavior when interrupted by calls, messages, or switching apps.
8. Installation & Update Testing
o To check smooth installation, upgrade, and rollback across supported devices.
(ii) For each type of test, specify the test objectives and descriptions:
Test Type Objective Description
Functional Ensure all banking features Test login, fund transfer, mini-
Testing function correctly. statement, etc.
App behaves correctly
Compatibility Run tests on various
across devices, OS, screen
Testing devices/emulators.
sizes.
Simulate many users
Performance App maintains speed and
transferring funds
Testing stability under varying load.
simultaneously.
Usability Ensure app is intuitive and Test layout, navigation, and
Testing easy to use. error messages.
Test encryption, session
Security Ensure user data and
management, data leakage,
Testing transactions are secure.
etc.
Configuration Validate app under various Change settings like language,
Testing device configurations. theme, or date/time format.
Verify app resumes or
Interrupt Simulate incoming calls/SMS
handles interruptions
Testing during transactions.
gracefully.
Install/Update Ensure error-free installation Check install/uninstall and
Testing or version upgrade. update scenarios.