Software Testing Lab Manual
Experiment 1: Test Plan for E-Commerce Application
Aim: To create a comprehensive test plan for www.amazon.in.
Algorithm:
1. Understand application features.
2. Define scope, objectives, and resources.
3. Identify types of testing required.
4. Define entry/exit criteria and risk.
Procedure:
Open Amazon and explore its features.
Identify modules like login, search, cart, checkout.
Create a document with test scope, environment, team, etc.
Result: A detailed test plan for Amazon with all standard components.
Experiment 2: Design Test Cases for E-Commerce Application
Aim: To design manual test cases for an e-commerce platform.
Algorithm:
5. Break down the application into features.
6. For each feature, create test cases.
7. Include input, expected output, and steps.
Procedure:
Identify modules like login, search, add to cart.
Write test cases with test steps, expected and actual results.
Result: Test case document covering multiple scenarios.
Experiment 3: Execute Test Cases and Report Defects
Aim: To execute test cases on www.amazon.in and report bugs.
Algorithm:
8. Execute test cases.
9. Compare expected vs actual result.
10. Log bugs with proper severity and steps.
Procedure:
Run test case TC001 (Login).
If login fails with valid data → report defect.
Use Excel or tools like JIRA/Bugzilla.
Result: Defect report with severity, description, and screenshots.
Experiment 4: Test Plan and Test Cases for Inventory Control System
Aim: To create a test plan and design test cases for an inventory management application.
Algorithm:
11. Identify modules (Add, Update, Delete, Reports).
12. Prepare test plan.
13. Write test cases for each function.
Procedure:
Identify features of the inventory control system.
Create a test plan and detailed test cases.
Result: Test plan and test case document for inventory app.
Experiment 5: Test Desktop/Client-Server App
Aim: To execute test cases on a desktop or client-server application and log defects.
Procedure:
Choose a desktop app (e.g., Calculator, Notepad).
Write test cases like 'check addition'.
Run tests and note mismatches.
Report defects.
Result: Defect report with observations.
Experiment 6: Performance Testing of E-Commerce App
Aim: To measure performance of an e-commerce website using JMeter.
Algorithm:
14. Open JMeter.
15. Create thread group, HTTP request, listeners.
16. Set users and duration.
17. Analyze results.
Result: Graph and metrics showing site response under load.
Experiment 7: Selenium Automation for E-Commerce Website
Aim: To automate product search on Amazon using Selenium WebDriver.
Sample Code:
WebDriver driver = new ChromeDriver();
driver.get("https://www.amazon.in");
driver.findElement(By.id("twotabsearchtextbox")).sendKeys("mobile");
driver.findElement(By.id("nav-search-submit-button")).click();
Result: Test executed and Amazon search automated successfully.
Experiment 8: Integrate Selenium with TestNG
Aim: To integrate TestNG with Selenium for test case management.
Sample Code:
@Test
public void testSearch() {
driver.findElement(By.id("twotabsearchtextbox")).sendKeys("Laptop");
}
Result: Tests executed using TestNG with better reporting.
Experiment 9: Mini Project (Framework Building)
Aim: To build different Selenium frameworks using TestNG, Apache POI, and Cucumber.
Procedure:
a) Data-Driven: Use Excel with Apache POI or DataProvider.
b) POM: Create Java classes for each page and reuse methods.
c) BDD: Write .feature file, define steps, and run using Cucumber.
Result: Reusable and maintainable test frameworks developed.