Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
138 changes: 138 additions & 0 deletions docs/automated-testing/requirements.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# Bistro Delivery Automated Testing Requirements

## Cart and Checkout Tests Requirements {#auto-req-1}

**Title:** Product List Verification in Checkout
**Description:** Verify cart items and totals are correctly displayed on checkout page

#### Test Requirements:

- Validate cart items list matches added products
- Verify total price calculations
- Test cart item removal functionality
- Verify cart state after item removal
- Test adding items back to cart
- Validate final cart state after modifications

**Title:** Order Placement with Cash Payment
**Description:** Verify successful order placement with valid data and cash payment

#### Test Requirements:

- Validate order items display
- Verify form field validation:
- Name input
- Email input
- Payment method selection
- Validate payment methods list
- Verify order placement success

## Content Verification Tests Requirements {#auto-req-2}

**Title:** About Us Content Verification
**Description:** Verify About Us page content accuracy

#### Test Requirements:

- Validate page heading matches expected text
- Verify body content contains specific text
- Ensure content formatting is preserved

**Title:** Navigation Bar Display Verification
**Description:** Verify navbar elements and active states

#### Test Requirements:

- Validate navbar items list:
- Welcome
- Today's Menu
- About us
- Verify active states on different pages
- Test navigation state persistence
- Known issues to verify:
- Bug: Today's Menu active state incorrect
- Bug: About us active state incorrect

## Menu Display Tests Requirements {#auto-req-3}

**Title:** Default Menu Display Verification
**Description:** Verify menu tabs and content display

#### Test Requirements:

- Validate default pizza menu display
- Verify tab states:
- PIZZAS
- DRINKS
- DESSERTS
- Test menu content for each tab
- Verify active state changes
- Validate menu item presence

**Title:** Welcome Banner Menu Navigation
**Description:** Verify Today's Menu access from welcome banner

#### Test Requirements:

- Validate welcome page content:
- Heading text
- Body text
- Menu button text
- Verify navigation functionality

## Test Data Requirements

### Menu Items

```typescript
interface MenuItem {
name: string
price: number
}

interface CartResponse {
items: Array<{
name: string
amount: number
}>
total: number
}
```

### Form Data

```typescript
interface OrderData {
name: string // e.g., "John Doe"
email: string // e.g., "johndoe@example.com"
paymentMethod: string // Must be from paymentMethods array
}
```

## Test Environment Requirements

### Page Objects Required

- Menu
- Cart
- Checkout
- Welcome
- About

### Browser Requirements

- Tests must run in Playwright-supported browsers
- Viewport must be set to desktop dimensions
- JavaScript must be enabled

## Performance Requirements

- Page navigation should complete within test timeouts
- Cart operations should be immediate
- Form submissions should complete within standard timeout

## Error Handling Requirements

- Tests should handle async operations properly
- Proper error messages for failed assertions
- Timeout handling for network requests
Binary file added docs/manual-testing/images/req-1-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-1-2.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-2-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-3-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-4-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-5-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/manual-testing/images/req-6-1.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading