EX NO 1 MATRIX MULTIPLICATION
Aim:
To develop the test cases to perform matrix multiplication using Java
Algorithm:
Step 1: Check the compatibility of the matrix by checking that the number of
columns in the 1st matrix equals the number of rows in the 2nd matrix.
Step 2: Multiply the elements in the first row of the first matrix with the elements
in the first column of the matrix and find the sum of all the products. Then multiply
the element in the first row of the first matrix with the elements of the second column
in the second matrix. Repeat this process till elements of all the positions are not
obtained.
Step 3: Substitute all the elements obtained in Step 2 in their respective position to
find the required product matrix.
Possible TestCases:
[Link] of Columns in First Matrix equals the number of rows in Second Matrix
[Link] of Columns in First Matrix doesn’t match with the number of rows in the
Second Matrix
[Link] Values or Non-numeric values entered as Matrix Values.
Program:
import [Link];
public class MatrixMultiplicationExample {
public static void main(String args[]) {
int row1, col1, row2, col2;
Scanner s = new Scanner([Link]);
// Input dimensions of First Matrix: A
[Link]("Enter number of rows in first matrix: ");
row1 = [Link]();
[Link]("Enter number of columns in first matrix: ");
col1 = [Link]();
// Input dimensions of second matrix: B
[Link]("Enter number of rows in second matrix: ");
row2 = [Link]();
[Link]("Enter number of columns in second matrix: ");
col2 = [Link]();
// Requirement check for matrix multiplication
if (col1 != row2) {
[Link]("Matrix multiplication is not possible");
return;
}
int a[][] = new int[row1][col1];
int b[][] = new int[row2][col2];
int c[][] = new int[row1][col2];
// Input the values of matrices
[Link]("\nEnter values for matrix A : ");
for (int i = 0; i < row1; i++)
{
for (int j = 0; j < col1; j++)
a[i][j] = [Link]();
}
[Link]("\nEnter values for matrix B : ");
for (int i = 0; i < row2; i++)
{
for (int j = 0; j < col2; j++)
b[i][j] = [Link]();
}
// Perform matrix multiplication
// Using for loop
[Link]("\nMatrix multiplication is : ");
for (int i = 0; i < row1; i++)
{
for (int j = 0; j < col2; j++)
{
// Initialize the element C(i,j) with zero
c[i][j] = 0;
// Dot product calculation
for (int k = 0; k < col1; k++)
{
c[i][j] += a[i][k] * b[k][j];
}
[Link](c[i][j] + " ");
}
[Link]();
}
}
}
Output:
Enter number of rows in first matrix: 3
Enter number of columns in first matrix: 2
Enter number of rows in second matrix: 2
Enter number of columns in second matrix: 4
Enter values for matrix A :
1
2
34
4
56
6
Enter values for matrix B :
2
1
4
6
3
7
5
8
Matrix multiplication is :
8 15 14 22
18 31 32 50
28 47 50 78
Result:
Test cases are developed to perform matrix multiplication and the matrix multiplication
using Java is executed successfully.
EX NO 2 TEST PLAN FOR E-COMMERCE APPLICATION
Aim
To develop the tests plan for testing an e-commerce web/mobile application
([Link]).
TEST PLAN
1. Testing Homepage of an ecommerce Site
2. Testing the Master page of an Online Shopping Website
3. Testing the Login & Registration flow of an eCommerce Site
4. Testing the My Account of an Online Web Store
5. Testing the Search feature of an eCommerce Site
6. Testing the Categories or Product Listing Page (PLP) of an Online ShoppingStore
7. Testing the Product Details Page (PDP) of an eCommerce Site
8. Testing the Shopping Cart of an Online Shopping Platform
9. Testing the Checkout Flow of an ecommerce Site
10. Testing the Order Confirmation Page of an Online Shopping Portal
OUTPUT:
HOMEPAGE
MASTER PAGE
LOGIN & REGISTRATION FLOW
SEARCH FUNCTIONALITY & PRODUCT LISTING PAGE
PRODUCT DETAILS PAGE
CHECKOUT FLOW
Result:
The tests plan are developed for testing an e-commerce web/mobile application.
([Link]).
EX NO :3 DEVELOP TEST CASES FOR E -COMMERCEAPPLICIATION
Aim:
To develop Test Cases For E -CommerceApplication
Test Cases:
HOME PAGE
Test
Module Name Test Scenario Test Case
Case ID
Verify that home page is displayed
TC001 Home Page Verify the details on Home page after login or not.
Verify that user name is displayed on
TC002 Home Page Verify the details on Home page
home page or not
TC003 Home Page Verify the details on Home page Verify that featured products are
displayed on home page
TC004 Home Page Verify the details on Home page Verify that Search Functionality is
present on home page.
Verify the home page of application
TC005 Home Page Verify the details on Home page
on different browsers.
TC006 Home Page Verify the details on Home page Verify the alignment on the home page
TC007 Home Page Verify the details on Home page Verify that products displayed on
home page are clickable.
Verify that when user clicks on a
TC008 Home Page Verify the details on Home page product, user should be redirected to
product specification page.
TC009 Home Page Verify the details on Home page Verify that user profile section is
present on home page.
TC0010 Home Page Verify the details on Home page Verify that products displayed on
home page are categorised.
SEARCH FUNTIONALTY
Test Module
Case Name Test Scenario Test Case
ID
TC001 Product Verify the product Verify that search field accepts alphabets,
Search search functionality numbers or symbols.
TC002 Product Verify the product Verify that after entering search text and clicking on
Search search functionality search icon, the search should be performed.
TC003 Product Verify the product Verify that the search results should be as per the
Search search functionality search query.
TC004 Product Verify the product Verify that user should be able to search based on
Search search functionality product name,brand name or product
specification.
TC005 Product Verify the product Verify that filter should be present for filtering the
Search search functionality search results bases on Brand, Price, Reviews or
Ratings.
TC006 Product Verify the product Verify that sorting options should be present on
Search search functionality search results page.
TC007 Product Verify the product Verify that the number of search results displayed
Search search functionality on one page.
PRODUCT DETAILS
Test
Case Module Name Test Scenario Test Case
ID
Product Verify the details on Verify that images of product
TC001
Details Product Specification page are displayed correctly.
TC002 Product Verify the details on Verify that price of product is
Details Product Specification page displayed.
Product Verify the details on Verify that product reviews
TC003
Details Product Specification page are mentioned.
TC004 Product Verify the details on Verify that product specifications
Details Product Specification page are displayed.
Verify that information about
Product Verify the details on
TC005 IN- Stock/Out-Stock are
Details Product Specification page
displayed.
Product Verify the details on Verify that seller ratings should
TC006
Details Product Specification page be displayed.
CART PAGE
Test Module Test Scenario Test Case
Case Name
ID
Verify the details on Cart Verify that when user clicks on add to cart,
TC001 Cart Page Page
the product should be added to cart.
Verify the details on Cart Verify that user should be able to continue
TC002 Cart Page Page
shopping after adding items to cart.
Verify the details on Cart Verify that item quantity should be
TC003 Cart Page Page increased if user adds same item in cart
again.
Verify the details on Cart Verify that total amount of all items
TC004 Cart Page Page
should be displayed to user.
TC005 Cart Page Verify
Page
the details on Cart Verity that the amount displayed to user
CHECK OUT, PAYMENT PAGE
Test Module Name Test Scenario Test Case
Case ID
TC001 Checkout, Verify the details on Verify that payments options applicable
Pay ments Checkout,Payments Page for the order should be displayed at
Page checkout.
Test Module Name Test Scenario Test Case
Case ID
TC002 Checkout,Pay ments Verify the details on Verify that delivery details of items
Page Checkout,Payments should be displayed at checkout.
Page
TC003 Checkout,Pay ments Verify the details on Verify that user should get order details
Page Checkout,Payments by message or email.
Page
TC004 Checkout,Pay ments Verify the details on Verify that user should be directed to
Page Checkout,Payments home page after checkout.
Page
TC005 Checkout,Pay ments Verify the details on Verify that user should be displayed
Page Checkout,Payments payment options such as Credit Card,
Page Debit Card, Net Banking etc.
TC006 Checkout,Pay ments Verify the details on Verify that if user is not registered then
Page Checkout,Payments payment should be done as Guest user.
Page
TC007 Checkout,Pay ments Verify the details on Verify that user should be provided
Page Checkout,Payments with an option to save the payment
Page method.
TC008 Checkout,Pay ments Verify the details on Verify that session should be timed out
Page Checkout,Payments if payment is not done for a certain
Page time.
TC009 Checkout,Pay Verify the details on Verify that user details should be
ments Page Checkout,Payments displayed on payment page for
Page
MY ORDER PAGE
Test Module Name Test Scenario Test Case
Case ID
TC001 My Orders Page Verify the details on Verify that user should be able to
Orders Page track the order on My orders page.
TC002 My Orders Page Verify the details on Verify that user should be able to
Orders Page change the delivery date and time.
TC003 My Orders Page Verify the details on Verify that user should be able to
Orders Page cancel the order
TC004 My Orders Page Verify the details on Verify that user should be able to return
Orders Page the order after delivery of order.
TC005 My Orders Page Verify the details on Verify that user should be able to
Orders Page exchange the order from My orders
page.
C006 My Orders Page Verify the details on Verify that user should be able to
Orders Page provide feed back and reviews about the
item delivered.
CUSTOMER SERVICE PAGE
Test Case Module Test Scenario Test Case
ID Name
TC001 Customer Verify the details on Customer Verify that customer service
Service Page Service Page options should be present on the
website.
TC002 Customer Verify the details on Customer Verify that different modes of
Service Page Service Page customer service such as Email,
Chat or Call should be mentioned.
TC003 Customer Verify the details on Customer Verify that waiting time to connect
Service Page Service Page to customer service shold be
displayed to user.
TC004 Customer Verify the details on Customer Verify that customer service
Service Page Service Page should be available in different
languages.
TC005 Customer Verify the details on Customer Verify that the timings of customer
Service Page Service Page service option should be displayed to
user.
RESULT:
Test Cases are developed for E -CommerceApplication
[Link] TEST THE E-COMMERCE APPLICATION AND REPORT DEFECTS IN IT
AIM:
To Test The E-Commerce Application And Report Defects in it
TESTING & BUG REPORTING
HOME PAGE
Test Scenario: Verify the details on Home page
Test Case: Verify that home page is display ed after login or not.
Pre- requisites : Browser should be installed Internet connectio n should be present
Test Data: Username,- / Username,Password /-, - / -,Password
Expected Result: Home page should be displayed after login and user name should
be displayed on home page.
Bug:
SEARCH FUNTIONALTY
Test Scenario: Verify the product search functiona lity
Test Case:
1. Verify that search field accepts alphabets ,numbers or symbols.
2. Verify that after entering search text and clicking on search icon, search should be performe d.
3. Browser should be installed Internet connection should be present User should be logged in.
Pre- requisites : Browser should be installed Internet connection should be present.
Test Data: Username,- / Username,Password /-, - / -,Password/Product to be searched.
Expected Result: Search should be performed according to search text provided by user.
Bug:
PRODUCT DETAILS
Test Scenario: Verify the details on Product Specific ation page
Test Case: Verify that images of produc t are displa yed correct ly
Verify that price of produc t is displa yed.
Pre- requisites : Browser should be installed Internet connectio n should be present
Test Data: Product to be searched
Expected Result: Product Details and the images of product should be displayed
correctly.
:
CART PAGE
Test Scenario: Verify the details on Cart Page
Test Case: Verify that when user clicks on add to cart, the produc t should be added to cart.
Pre- requisites : Browser should be installed Internet connectio n should be present
Test Data: Username,- / Username,Password /-, - / -,Password,Products to be added to cart
Expected Result: The product should be added to cart.
BUG:
CHECK OUT ,PAYMENT
Test Scenario: Verify the details on Checko ut,Paym ents Page
Test Case: Verify that deliver y details of items should be display ed at checko ut.
Pre- requisites : Browser should be installed Internet connectio n should be present
Test Data: Username,- / Username,Password /-, - / -,Password / Payment Credentials
Expected Result: The checkout page should be displayed with payments options.
BUG:
RESULT:
The E-Commerce Application is tested And defects in it was reported as bugs
EX NO : 5 TEST PLAN AND TEST CASES FOR AN INVENTORY CONTROL SYSTEM
AIM:
To develop Test Plan And Test Cases For An Inventory Control System
TEST PLAN FOR AN INVENTORY CONTROL SYSTEM
1. Objective: The primary goal is to ensure the Inventory Control System accurately
records, monitors, and manages inventory levels, facilitating seamless operations for
the organization.
2. Scope: This test plan encompasses functional, performance, security, and usability
testing of the Inventory Control System. It includes testing inventory tracking, data
input/output, user authentication, system response times, and user interface.
3. Test Cases: a. Functional Testing:
• Verify inventory addition, deletion, and modification functionalities.
• Validate inventory search and retrieval operations. b. Performance Testing:
• Evaluate system response times under varying loads.
• Assess system scalability to handle large volumes of inventory transactions. c.
Security Testing:
• Test user authentication mechanisms to ensure secure access.
• Verify data encryption and protection against unauthorized access. d. Usability
Testing:
• Assess the intuitiveness of the user interface for easy navigation.
• Validate the efficiency of inventory management tasks for end-users.
4. Execution:
• Conduct tests in a controlled testing environment that mimics the production
environment.
• Utilize automated testing tools for repetitive tasks to enhance efficiency.
• Involve stakeholders and domain experts for comprehensive validation.
5. Validation:
• Engage end-users and stakeholders to validate system functionalities and
usability.
• Gather feedback to identify areas for improvement and refinement.
6. Documentation:
• Document test cases, test results, and any issues encountered during testing.
• Provide recommendations for addressing identified issues and enhancing
system performance and security.
TEST CASES FOR INVENTORY MANAGEMENT SYSTEM
[Link] Test Action Steps Input Data Experienced Actual status
Case result result
ID
1 TC−1 Invoice no Enter Input*1021* It should
Invoice accepted
no invoice no.
2 TC−2 Bill date Enter Bill Input*27/11/202 It should
date 1* accepted bill
date
3 TC−3 Item name select − Item name
Item should be
name automatically
reflected
4 TC−4 Available item Click on − It should
stock text box reflect
automatically
item stock
5 TC−5 Quantity Enter Input*5000* Item quantity
item should be
quantity accepted
6 TC−6 Price Click on − Price should
text box be reflected
automatically
7 TC−7 Total Click on − Total should
text box be reflected
automatically
8 TC−8 Receive bill Enter Input*29/1/2021 Receive bill
date receive date should
bill date be accepting
9 TC−9 Add item Click on − It should be
add item add item
reflecting in
database
RESULT:
Test Plan And Test Cases For An Inventory Control System is developed.