Brings the working codebase (Next.js app, auth system, Stripe billing, Docker/deploy config, tests, docs) into version control on top of the placeholder initial commit, and adds account self-deletion (Danger Zone in Settings, password + typed-email confirmation, cascading DB cleanup, Stripe cancellation) per GDPR right-to-erasure. Excludes local build caches, node_modules, and internal agent scratch files; .gitignore hardened to keep those out going forward. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
3.2 KiB
3.2 KiB
E2E Test Infra: Receipt Scanner UI/UX Upgrade
Test Philosophy
- Opaque-box, requirement-driven verification derived directly from
ORIGINAL_REQUEST.md. - Methodology: Category-Partition + Boundary Value Analysis + Pairwise Combinations + Real-World Workload Testing.
Feature Inventory Mapping
| # | Feature | Requirement | Tier 1 (Feature) | Tier 2 (Boundary) | Tier 3 (Pairwise) | Tier 4 (Scenario) |
|---|---|---|---|---|---|---|
| 1 | Global Dropzone Overlay | R1 | 5 | 5 | ✓ | ✓ |
| 2 | Dedicated Dropzone Component | R1 | 5 | 5 | ✓ | ✓ |
| 3 | Batch Upload Drawer & Queue | R1 | 5 | 5 | ✓ | ✓ |
| 4 | Error Boundaries & Retry | R1 | 5 | 5 | ✓ | ✓ |
| 5 | Side-by-Side Review Modal | R2 | 5 | 5 | ✓ | ✓ |
| 6 | Interactive Document Viewer | R2 | 5 | 5 | ✓ | ✓ |
| 7 | Bounding-Box Visual Sync | R2 | 5 | 5 | ✓ | ✓ |
| 8 | Dynamic Line Items Editor | R2 | 5 | 5 | ✓ | ✓ |
| 9 | Field Audit & Auto-Save | R2 | 5 | 5 | ✓ | ✓ |
| 10 | Payment Method Selection | R2 | 5 | 5 | ✓ | ✓ |
| 11 | Editable Table Affordances | R3 | 5 | 5 | ✓ | ✓ |
| 12 | 3-Tier Status Badges | R3 | 5 | 5 | ✓ | ✓ |
| 13 | Floating Batch Actions Bar | R3 | 5 | 5 | ✓ | ✓ |
| 14 | Filter Chips Bar | R3 | 5 | 5 | ✓ | ✓ |
| 15 | Responsive Navigation Shell | R4 | 5 | 5 | ✓ | ✓ |
| 16 | Interactive KPI Metric Cards | R4 | 5 | 5 | ✓ | ✓ |
| 17 | Accessible Layout & Contrast | R4 | 5 | 5 | ✓ | ✓ |
Test Architecture
- Framework: Jest / React Testing Library (
npm test) & Vitest/Node test runner - Build Verification:
npx tsc --noEmit&npm run build - E2E & Component Test Directory:
src/__tests__/andsrc/components/dashboard/__tests__/
Real-World Application Scenarios (Tier 4)
| # | Scenario | Features Exercised | Expected Outcome |
|---|---|---|---|
| 1 | Batch upload mixed PDF & PNG receipts | F1, F2, F3, F4 | All files queued, progress tracked, thumbnails rendered, valid files parsed |
| 2 | Corrupted file in multi-file batch | F3, F4, F12 | Corrupt file flagged with error, retry button available, other files successfully ingested |
| 3 | Side-by-side inspect, edit line item & auto-save | F5, F6, F7, F8, F9, F10 | Dual pane opened, zoom/pan operational, field focus highlights box, math recalculates, saved to IDB |
| 4 | Multi-select bulk export & bulk status update | F11, F12, F13, F14 | Checkbox selection triggers floating bar, bulk export generates XLSX/CSV, bulk status sets Confirmed |
| 5 | Filter chips navigation & KPI card click-through | F14, F16, F15 | Clicking "Pending Reviews" card filters table to pending items, chip states update dynamically |
| 6 | Responsive mobile viewport transition | F15, F17 | Screen <768px collapses sidebar into mobile drawer, zero horizontal overflow |
Coverage Goals
- Tier 1: ≥5 unit/component tests per feature (≥85 tests)
- Tier 2: ≥5 boundary tests (empty inputs, long strings, 0€ totals, 100+ files, malformed dates)
- Tier 3: Pairwise combinations of filter + batch actions + inspector edits
- Tier 4: ≥6 comprehensive end-to-end integration workflows