How to Write Test Cases for Cart Management (With Examples)
Writing effective test cases for cart management is crucial for ensuring a smooth and reliable e-commerce experience. This guide provides a practical framework for designing high-signal test cases, co
# How to Write Test Cases for Cart Management (With Examples)
Writing effective test cases for cart management is crucial for ensuring a smooth and reliable e-commerce experience. This guide provides a practical framework for designing high-signal test cases, covering everything from the anatomy of a good test case to specific examples for common cart functionalities. We will explore positive, negative, edge, and boundary scenarios, discuss data setup, prioritization, and traceability, and illustrate how well-designed test cases, when combined with autonomous exploration, can achieve comprehensive coverage of your cart management system.
Understanding Cart Management Functionality
Before diving into test case design, it’s essential to have a solid grasp of what cart management entails. At its core, cart management is the system that allows users to select items, add them to a temporary holding space (the shopping cart), modify the contents of that cart, and ultimately proceed to checkout or abandon their selections. This involves several key components:
- Adding Items: Users select products and add them to their cart. This often involves choosing variations like size, color, quantity, or specific configurations.
- Viewing the Cart: Users can access a summary of items currently in their cart, including product details, quantities, prices, and subtotals.
- Modifying Items: Users can change the quantity of existing items, remove items entirely, or in some cases, update product variations.
- Applying Promotions/Discounts: The cart is where users typically enter coupon codes or where automatic discounts are applied.
- Calculating Totals: The system must accurately calculate subtotals, taxes, shipping costs, and the grand total.
- Saving/Persistence: Carts may need to persist across sessions (e.g., for logged-in users) or be temporary (e.g., for guest users).
- Checkout Initiation: The cart serves as the gateway to the checkout process.
A robust cart management system is foundational to any successful e-commerce platform. Bugs in this area can lead to lost sales, customer frustration, and reputational damage. Therefore, meticulous test case design is not just a best practice; it's a business imperative.
Anatomy of a High-Signal Test Case
A well-written test case is more than just a set of steps and an expected outcome. It’s a clear, concise, and actionable instruction that helps a tester (human or automated) verify a specific piece of functionality. For cart management, where user interaction is key, precision is paramount.
A typical test case includes the following components:
- Test Case ID: A unique identifier for easy referencing and traceability. For example,
CART_ADD_001. - Test Title/Summary: A brief, descriptive name that summarizes the purpose of the test. E.g., "Verify adding a single item to an empty cart."
- Module/Feature: The specific part of the application being tested. E.g., "Shopping Cart."
- Preconditions: Any setup required before executing the test steps. This could include being logged in, having specific items in stock, or having no items in the cart.
- Test Steps: A numbered list of actions to perform. These should be explicit and unambiguous.
- Test Data: Any specific data required for the test, such as product IDs, quantities, or coupon codes.
- Expected Result: A clear description of what the system should do or display after the test steps are executed. This is the crucial part for determining pass/fail.
- Actual Result: (Filled in during execution) What actually happened.
- Status: (Filled in during execution) Pass/Fail/Blocked/Skipped.
- Priority: How important is this test? (e.g., P1 - Critical, P2 - High, P3 - Medium, P4 - Low).
- Tester/Date: Who executed the test and when.
- Notes/Comments: Any additional observations.
Example of a Basic Test Case Structure:
| Field | Description |
|---|---|
| Test Case ID | CART_ADD_001 |
| Test Title | Verify adding a single item to an empty cart. |
| Module | Shopping Cart |
| Preconditions | User is on the product details page. The cart is empty. The product is in stock. |
| Test Steps | 1. Click the "Add to Cart" button. 2. Navigate to the shopping cart page. |
| Test Data | Product: "Classic T-Shirt (Red, Medium)" |
| Expected Result | The shopping cart page displays "Classic T-Shirt (Red, Medium)" with a quantity of 1 and the correct price. The cart subtotal updates correctly. |
| Priority | P1 (Critical) |
For cart management, especially, the "Expected Result" needs to be very specific. It’s not enough to say "item is in cart." It needs to detail *which* item, *with what variations*, *what quantity*, and *how it affects the totals*.
Positive vs. Negative Testing
Positive test cases verify that the system works as expected under normal, valid conditions. These are the "happy path" scenarios. For cart management, this means successfully adding items, updating quantities, and proceeding to checkout with valid data.
Negative test cases verify that the system behaves gracefully and provides appropriate feedback when invalid data or unexpected actions are encountered. This is critical for preventing crashes and ensuring a good user experience even when users make mistakes or try to exploit the system.
Edge Cases and Boundary Value Analysis
Edge cases are conditions that occur at the extreme limits of valid input or operation. For cart management, this could involve adding the maximum allowed quantity of an item, adding an item that has a very high price, or interacting with the cart during a server outage (though this is harder to simulate).
Boundary Value Analysis (BVA) is a technique where we test at the edges of valid ranges. If the system allows a maximum quantity of 99 items, we should test:
- 99 (maximum valid)
- 100 (one above maximum)
- 1 (minimum valid)
- 0 (one below minimum, if applicable or if it means removal)
These values are often where bugs hide.
Data Setup and Management
Effective test case writing for cart management heavily relies on having appropriate test data. This includes:
- Products: A diverse range of products with different pricing, stock levels, variations (size, color, etc.), and potentially special attributes (e.g., taxable, requires shipping).
- User Accounts: Different types of user accounts (guest, registered, premium, etc.) may have different cart behaviors or permissions.
- Promotions/Coupons: Valid and invalid coupon codes, codes with specific conditions (e.g., minimum purchase, specific items), expired codes, and codes that have reached their usage limit.
- Configurations: Different tax rates, shipping options, and currency settings.
Considerations for Test Data:
- Data Variety: Ensure your data covers various scenarios (e.g., products with and without variations, products with different tax statuses).
- Data State: Be mindful of the state of your data. Is the product in stock? Is the coupon code active? Has the coupon code reached its usage limit?
- Data Isolation: For automated tests, ensure that test runs do not interfere with each other due to shared data states (e.g., a coupon code used up by a previous test).
- Data Generation: For large-scale testing, consider programmatic data generation or using tools that can seed your test environment with realistic data.
Designing Test Cases for Core Cart Functionalities
Let's break down the design of test cases for the most common cart management features. We'll aim for a mix of positive, negative, and edge cases.
Adding Items to the Cart
This is the most fundamental operation.
Test Case Examples:
- CART_ADD_001: Add a single, in-stock item with no variations to an empty cart.
- Preconditions: User on Product A page (no variations, in stock). Cart is empty.
- Steps: 1. Click "Add to Cart." 2. Navigate to Cart.
- Expected: Cart shows 1 of Product A. Correct price and subtotal.
- CART_ADD_002: Add a single, in-stock item *with variations* to an empty cart.
- Preconditions: User on Product B page (variations: Red/M, Blue/L; in stock). Cart is empty.
- Steps: 1. Select "Red, Medium." 2. Click "Add to Cart." 3. Navigate to Cart.
- Expected: Cart shows 1 of Product B (Red, Medium). Correct price and subtotal.
- CART_ADD_003: Add an item that is out of stock.
- Preconditions: User on Product C page (out of stock). Cart is empty.
- Steps: 1. Attempt to add Product C.
- Expected: "Add to Cart" button is disabled or shows an "Out of Stock" message. User cannot add the item. No error message unless explicitly designed.
- CART_ADD_004: Add an item with maximum allowed quantity.
- Preconditions: Product D has a max quantity of 10. Cart is empty.
- Steps: 1. Set quantity to 10. 2. Click "Add to Cart." 3. Navigate to Cart.
- Expected: Cart shows 10 of Product D. Correct price and subtotal.
- CART_ADD_005: Attempt to add an item with quantity exceeding the maximum allowed.
- Preconditions: Product D has a max quantity of 10. Cart is empty.
- Steps: 1. Set quantity to 11. 2. Click "Add to Cart."
- Expected: System prevents adding the item, or automatically adjusts quantity to 10, and provides a clear message. The cart remains unchanged or updated to max.
- CART_ADD_006: Add an item with zero quantity.
- Preconditions: User on Product E page. Cart is empty.
- Steps: 1. Set quantity to 0. 2. Click "Add to Cart."
- Expected: Item is not added to the cart. Cart remains empty.
- CART_ADD_007: Add the same item multiple times (as separate line items if applicable, or to increase quantity).
- Preconditions: User on Product A page. Cart is empty.
- Steps: 1. Add Product A (quantity 1). 2. Go back to Product A page. 3. Add Product A again (quantity 1). 4. Navigate to Cart.
- Expected: Cart shows 2 of Product A, or two separate line items for Product A depending on system design. Quantity should be aggregated if that's the UX.
- CART_ADD_008: Add an item with a special character in its name or description.
- Preconditions: Product F has a name like "Widget & Gizmo." In stock. Cart empty.
- Steps: 1. Add Product F. 2. Navigate to Cart.
- Expected: Product F displays correctly in the cart without rendering issues or errors.
- CART_ADD_009: Add an item with a very high price.
- Preconditions: Product G has a price of $1,000,000. In stock. Cart empty.
- Steps: 1. Add Product G. 2. Navigate to Cart.
- Expected: Cart shows Product G with the correct high price. Subtotal calculation handles large numbers without overflow or precision errors.
- CART_ADD_010: Add an item with a very low price (e.g., $0.01).
- Preconditions: Product H has a price of $0.01. In stock. Cart empty.
- Steps: 1. Add Product H. 2. Navigate to Cart.
- Expected: Cart shows Product H with the correct low price. Subtotal calculation handles small numbers and potential rounding issues.
Viewing and Displaying Cart Contents
Once items are in the cart, how they are displayed is critical.
Test Case Examples:
- CART_VIEW_001: Verify cart total calculation with one item.
- Preconditions: Product A ($20) is in the cart with quantity 1.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $20. Tax and total are calculated correctly based on system configuration.
- CART_VIEW_002: Verify cart total calculation with multiple items of the same product.
- Preconditions: Product A ($20) is in the cart with quantity 3.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $60. Tax and total are calculated correctly.
- CART_VIEW_003: Verify cart total calculation with multiple different products.
- Preconditions: Product A ($20, Qty: 1) and Product B ($30, Qty: 2) are in the cart.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $20 + (2 * $30) = $80. Tax and total calculated correctly.
- CART_VIEW_004: Verify display of product image, name, variations, price, and quantity.
- Preconditions: Product B (Red, Medium, $30) is in the cart with quantity 2.
- Steps: 1. Navigate to Cart.
- Expected: Cart displays: Image of Product B, Name "Product B," Variations "Red, Medium," Unit Price "$30," Quantity "2," Line Item Total "$60."
- CART_VIEW_005: Verify cart with an item that has a zero price.
- Preconditions: Product I ($0) is in the cart with quantity 5.
- Steps: 1. Navigate to Cart.
- Expected: Product I displays with price $0. Line item total is $0. Subtotal calculation is not affected by this item.
- CART_VIEW_006: Verify cart with a large number of distinct items.
- Preconditions: Cart contains 50 different items, each with quantity 1.
- Steps: 1. Navigate to Cart.
- Expected: All 50 items are displayed correctly. Pagination is implemented if necessary. Totals are calculated accurately. Performance is acceptable.
- CART_VIEW_007: Verify cart with items that have different tax rates (if applicable).
- Preconditions: Product J (taxable, $50, Qty: 1) and Product K (non-taxable, $100, Qty: 1) are in the cart. Assume tax rate of 10%.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $150. Tax is calculated only on Product J ($5). Tax amount = $5. Total = $155.
- CART_VIEW_008: Verify cart persistence for a logged-in user across sessions.
- Preconditions: User logged in. Product L (Qty: 1) added to cart. User logs out.
- Steps: 1. Log back in. 2. Navigate to Cart.
- Expected: Product L (Qty: 1) is still in the cart.
- CART_VIEW_009: Verify cart behavior for a guest user across browser sessions (if supported).
- Preconditions: User is a guest. Product M (Qty: 1) added to cart. Browser closed.
- Steps: 1. Re-open browser. 2. Navigate to Cart.
- Expected: Product M (Qty: 1) is still in the cart (if session/cookie persistence is implemented).
Modifying Cart Contents
Users need to be able to adjust their selections.
Test Case Examples:
- CART_MOD_001: Increase quantity of an item.
- Preconditions: Product A ($20) is in the cart with quantity 1.
- Steps: 1. On the cart page, change quantity of Product A to 3. 2. Click "Update Cart" (or observe auto-update).
- Expected: Quantity for Product A is 3. Line item total is $60. Cart subtotal and total are updated correctly.
- CART_MOD_002: Decrease quantity of an item.
- Preconditions: Product A ($20) is in the cart with quantity 3.
- Steps: 1. On the cart page, change quantity of Product A to 1. 2. Click "Update Cart."
- Expected: Quantity for Product A is 1. Line item total is $20. Cart subtotal and total are updated correctly.
- CART_MOD_003: Decrease quantity to zero (should effectively remove the item).
- Preconditions: Product A ($20) is in the cart with quantity 2.
- Steps: 1. On the cart page, change quantity of Product A to 0. 2. Click "Update Cart."
- Expected: Product A is removed from the cart. Cart subtotal and total reflect the removal.
- CART_MOD_004: Remove an item from the cart.
- Preconditions: Product A ($20, Qty: 1) and Product B ($30, Qty: 1) are in the cart.
- Steps: 1. Click the "Remove" button for Product A.
- Expected: Product A is removed. Cart subtotal and total are updated to reflect only Product B.
- CART_MOD_005: Attempt to increase quantity beyond maximum allowed.
- Preconditions: Product D (max qty 10, $15) is in the cart with quantity 9.
- Steps: 1. On the cart page, attempt to change quantity of Product D to 11. 2. Click "Update Cart."
- Expected: System prevents the update or adjusts to 10 and shows a message. Cart reflects quantity 10. Subtotal updated correctly.
- CART_MOD_006: Attempt to decrease quantity below zero (if input allows).
- Preconditions: Product A ($20) is in the cart with quantity 2.
- Steps: 1. On the cart page, enter "-1" for quantity of Product A. 2. Click "Update Cart."
- Expected: System prevents the update or treats it as 0/removes the item. Cart reflects valid state.
- CART_MOD_007: Modify quantity of an out-of-stock item (if it was somehow added).
- Preconditions: Product C (out of stock) is in the cart with quantity 1.
- Steps: 1. On the cart page, attempt to increase quantity to 2. 2. Click "Update Cart."
- Expected: System prevents the update and displays an "Out of Stock" message. Item remains quantity 1 or is removed.
- CART_MOD_008: Modify quantity of an item that has had its price changed since being added.
- Preconditions: Product A ($20) was added. Price is now $25. Product A (Qty: 1) is in cart.
- Steps: 1. On the cart page, change quantity of Product A to 2. 2. Click "Update Cart."
- Expected: Quantity becomes 2. Line item total now reflects the *new* price ($50). Cart totals update accordingly.
- CART_MOD_009: Modify quantity of an item that has since become out of stock.
- Preconditions: Product A ($20) was added (Qty: 1). Product A is now out of stock.
- Steps: 1. Navigate to Cart.
- Expected: Cart displays an "Out of Stock" message for Product A. Quantity might be reset to 0 or item removed. User is prevented from proceeding to checkout with this item.
Applying Promotions and Discounts
This is a common source of bugs and revenue loss if implemented incorrectly.
Test Case Examples:
- CART_PROMO_001: Apply a valid coupon code for a percentage discount.
- Preconditions: Cart total > $50. Coupon
SUMMER10(10% off) is active and has sufficient uses. - Steps: 1. Enter
SUMMER10in the coupon field. 2. Click "Apply Coupon." - Expected: Discount amount (10% of subtotal) is displayed. Cart total is reduced by the discount. Coupon is shown as applied.
- CART_PROMO_002: Apply a valid coupon code for a fixed amount discount.
- Preconditions: Cart total > $20. Coupon
SAVE20($20 off) is active. - Steps: 1. Enter
SAVE20. 2. Click "Apply Coupon." - Expected: Discount amount ($20) is displayed. Cart total is reduced by $20.
- CART_PROMO_003: Apply an invalid/non-existent coupon code.
- Preconditions: Cart is active.
- Steps: 1. Enter
INVALIDCODE. 2. Click "Apply Coupon." - Expected: An error message is displayed (e.g., "Coupon code not found"). Cart totals remain unchanged.
- CART_PROMO_004: Apply an expired coupon code.
- Preconditions: Cart is active. Coupon
EXPIRED5was valid but has expired. - Steps: 1. Enter
EXPIRED5. 2. Click "Apply Coupon." - Expected: An error message is displayed (e.g., "Coupon has expired"). Cart totals remain unchanged.
- CART_PROMO_005: Apply a coupon code that doesn't meet minimum purchase requirements.
- Preconditions: Cart subtotal is $40. Coupon
FREESHIPOVER50requires $50 minimum. - Steps: 1. Enter
FREESHIPOVER50. 2. Click "Apply Coupon." - Expected: An error message is displayed (e.g., "Minimum purchase of $50 required"). Cart totals remain unchanged.
- CART_PROMO_006: Apply a coupon code that has reached its usage limit.
- Preconditions: Coupon
LIMITED100has been used 100 times and limit is 100. Cart is active. - Steps: 1. Enter
LIMITED100. 2. Click "Apply Coupon." - Expected: An error message is displayed (e.g., "Coupon is no longer available"). Cart totals remain unchanged.
- CART_PROMO_007: Apply a coupon code for a specific product/category that is not in the cart.
- Preconditions: Cart contains Product A ($20). Coupon
SHIRTDEALapplies only to Product B. - Steps: 1. Enter
SHIRTDEAL. 2. Click "Apply Coupon." - Expected: An error message is displayed (e.g., "Coupon not applicable to items in your cart"). Cart totals remain unchanged.
- CART_PROMO_008: Apply a coupon code that results in a negative total.
- Preconditions: Cart subtotal is $10. Coupon
SAVE20($20 off). - Steps: 1. Enter
SAVE20. 2. Click "Apply Coupon." - Expected: Discount is applied, but the final total should not go below zero. It should be $0.
- CART_PROMO_009: Apply multiple compatible coupon codes (if supported).
- Preconditions: Cart subtotal $100. Coupon
SAVE10(10% off) and CouponEXTRA5($5 off) are compatible. - Steps: 1. Apply
SAVE10. 2. ApplyEXTRA5. - Expected: Both discounts are applied correctly (order of application may matter). Total is reduced by 10% and then $5.
- CART_PROMO_010: Apply multiple incompatible coupon codes (if supported).
- Preconditions: Cart subtotal $100. Coupon
SAVE10(10% off) and CouponSUMMER SALE(15% off) are incompatible. - Steps: 1. Apply
SAVE10. 2. Attempt to applySUMMER SALE. - Expected: An error message indicates incompatibility, or the second coupon overrides the first, or only the best discount is applied based on system rules. The cart reflects the correct outcome based on defined rules.
- CART_PROMO_011: Remove an applied coupon code.
- Preconditions: Coupon
SAVE10($10 off) is applied to a cart. - Steps: 1. Click "Remove Coupon."
- Expected: Discount is removed. Cart total reverts to the pre-discount amount.
Cart Totals and Calculations
Accurate calculation of all monetary values is paramount.
Test Case Examples:
- CART_TOTAL_001: Verify subtotal calculation with various quantities and prices.
- Preconditions: Cart contains Product A ($10, Qty: 2) and Product B ($25, Qty: 3).
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = (2 * $10) + (3 * $25) = $20 + $75 = $95.
- CART_TOTAL_002: Verify tax calculation for a taxable item in a taxable region.
- Preconditions: Cart has Product A ($10, Qty: 1). Tax rate is 8%. Product A is taxable.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $10. Tax = $10 * 0.08 = $0.80. Total = $10.80.
- CART_TOTAL_003: Verify tax calculation for a non-taxable item.
- Preconditions: Cart has Product B ($20, Qty: 1). Tax rate is 8%. Product B is non-taxable.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $20. Tax = $0. Total = $20.
- CART_TOTAL_004: Verify tax calculation with multiple items with different tax statuses.
- Preconditions: Cart has Product A ($10, Qty: 1, taxable) and Product B ($20, Qty: 1, non-taxable). Tax rate is 5%.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $30. Tax = $10 * 0.05 = $0.50. Total = $30.50.
- CART_TOTAL_005: Verify tax calculation when shipping address changes tax jurisdiction (if applicable).
- Preconditions: Cart has Product A ($10, Qty: 1). Initial region tax rate 5%. Target region tax rate 10%.
- Steps: 1. Add Product A to cart. 2. Proceed to shipping estimation/address entry. 3. Enter address in the 10% tax region. 4. Observe cart totals.
- Expected: Tax updates from 5% to 10%. Total reflects the updated tax.
- CART_TOTAL_006: Verify shipping cost calculation (flat rate).
- Preconditions: Cart has items. Flat rate shipping is $5.
- Steps: 1. Proceed to shipping estimation. 2. Select flat rate option.
- Expected: Shipping cost displayed as $5. Total updated.
- CART_TOTAL_007: Verify shipping cost calculation (weight-based, if applicable).
- Preconditions: Cart total weight is 5kg. Shipping cost is $1/kg.
- Steps: 1. Proceed to shipping estimation. 2. Select weight-based option.
- Expected: Shipping cost displayed as $5. Total updated.
- CART_TOTAL_008: Verify shipping cost calculation (free shipping threshold reached).
- Preconditions: Cart subtotal $80. Free shipping threshold is $75.
- Steps: 1. Proceed to shipping estimation.
- Expected: Shipping cost displayed as $0. Total updated.
- CART_TOTAL_009: Verify grand total calculation with items, tax, and shipping.
- Preconditions: Product A ($10, Qty: 1, taxable). Product B ($20, Qty: 1, non-taxable). Tax rate 10%. Shipping cost $5.
- Steps: 1. Navigate to Cart.
- Expected: Subtotal = $30. Tax = $10 * 0.10 = $1. Shipping = $5. Total = $30 + $1 + $5 = $36.
- CART_TOTAL_010: Verify total calculation after applying a discount.
- Preconditions: Cart subtotal $30. Tax 10% ($3). Shipping $5. Total $38. Coupon
SAVE5($5 off). - Steps: 1. Apply
SAVE5. - Expected: Discount $5. New Total = $38 - $5 = $33. (Note: Tax/Shipping might be recalculated based on discount application rules). Ensure consistency.
- CART_TOTAL_011: Verify calculation with non-default currency.
- Preconditions: Product A ($10 USD, Qty: 1). Store configured for EUR. Exchange rate applied.
- Steps: 1. Add Product A. 2. View cart.
- Expected: Price displayed in EUR. Subtotal and total calculated correctly in EUR.
- CART_TOTAL_012: Verify handling of floating-point precision issues.
- Preconditions: Add many items with prices like $0.03 to reach a subtotal.
- Steps: 1. Add 100 items of Product X ($0.03). 2. Navigate to Cart.
- Expected: Subtotal is exactly $3.00, not $2.9999999 or $3.0000001. All calculations are precise to two decimal places.
Checkout Initiation
The cart's final role is to funnel users towards checkout.
Test Case Examples:
- CART_CHECKOUT_001: Proceed to checkout with items in the cart.
- Preconditions: Cart contains at least one in-stock item. User is logged in or guest checkout is enabled.
- Steps: 1. Click "Proceed to Checkout."
- Expected: User is redirected to the first step of the checkout process (e.g., Shipping Address). Cart contents are passed to the checkout process.
- CART_CHECKOUT_002: Attempt to proceed to checkout with an empty cart.
- Preconditions: Cart is empty.
- Steps: 1. Attempt to click "Proceed to Checkout."
- Expected: Button is disabled, or user sees a message like "Your cart is empty." User is not allowed to proceed.
- CART_CHECKOUT_003: Attempt to proceed to checkout with only out-of-stock items.
- Preconditions: Cart contains only items marked as out-of-stock.
- Steps: 1. Attempt to click "Proceed to Checkout."
- Expected: User is prevented from proceeding. An appropriate message is displayed, perhaps highlighting the out-of-stock items.
- CART_CHECKOUT_004: Proceed to checkout after modifying cart contents.
- Preconditions: Cart contains Product A (Qty: 1). User changes quantity to 2.
- Steps: 1. Update quantity to 2. 2. Click "Proceed to Checkout."
- Expected: User proceeds to checkout. Checkout displays Product A with quantity 2 and the correct updated total.
- CART_CHECKOUT_005: Proceed to checkout after applying and then removing a coupon.
- Preconditions: Cart has items. Coupon
SAVE10applied. User removes coupon. - Steps: 1. Apply
SAVE10. 2. RemoveSAVE10. 3. Click "Proceed to Checkout." - Expected: User proceeds to checkout with the original cart total (before discount).
Test Case Matrix for Cart Management
Here’s a consolidated matrix that includes many of the cases discussed, organized by functionality.
| ID | Title | Preconditions | Steps | Expected Result | Priority |
|---|---|---|---|---|---|
| Add Items | |||||
CART_ADD_001 | Add single item, no variations, empty cart | Product A (in stock, no variations). Cart empty. | 1. Add Product A. 2. View Cart. |
Test Your App Autonomously
Upload your APK or URL. SUSA explores like 10 real users — finds bugs, accessibility violations, and security issues. No scripts.
Try SUSA Free