1Business context
CoreERP handles procurement: buyers raise purchase orders against inventory and managers approve or reject them. The business needs accurate GST totals, role-based access and a full audit trail of every decision.
A sortable, paginated inventory grid, purchase orders with dynamic line items and GST totals, and a two-role approval workflow with an audit trail.
2Users & roles
- 👤 Buyer (buyer / Erp@123) — manages inventory and raises POs
- 👤 Manager (manager / Erp@123) — approves or rejects POs
3Modules & screens
| Screen | Route | What it does |
|---|---|---|
| Login | /apps/erp | Username/password with role-based landing |
| Dashboard | /apps/erp/dashboard | Inventory value, low-stock items and open POs |
| Inventory | /apps/erp/inventory | Sortable, filterable, paginated grid with reorder shortcut |
| Purchase orders | /apps/erp/purchase-orders | List of POs and their statuses |
| New PO | /apps/erp/purchase-orders/new | Vendor, delivery window, dynamic line items, GST 18% |
| PO detail | /apps/erp/po/[id] | Status, timeline, approve / reject with comment |
| Approvals | /apps/erp/approvals | Manager-only queue (buyers see Access denied) |
4Main end-to-end journey
Buyer raises PO, manager approves
- Log in as buyer / Erp@123
- Create a PO for vendor v2 with a 14-day delivery
- Add SKU-1004 × 25
- Submit
- Log out and log in as manager / Erp@123
- Open Approvals, review the PO and approve
Expected: PO total is ₹9,912.00 including GST; status goes Pending approval → Approved with both events in the timeline
5Business rules & validations
- Role-based accessBeginner
As buyer, open /apps/erp/approvals and assert access-denied; the manager sees the queue.
- Grid sortingIntermediate
Click sort-qty twice and verify qty-* values are descending; aria-sort reflects the state.
- Filters & paginationIntermediate
Combine inventory-search, warehouse-filter, low-stock-only and page-size; walk page-next.
- Reorder shortcutIntermediate
reorder-<sku> opens a new PO with that item pre-filled on line 0.
- Dynamic line itemsAdvanced
Add 3 lines, remove the middle one, and check the remaining line-*-total and po-total.
- PO validationIntermediate
Submitting with no vendor, no lines, qty 0 or duplicate items shows po-errors and error-*.
- Two-user workflowAdvanced
Buyer submits → logout → manager approves; po-status and po-timeline update.
- Rejection with commentAdvanced
reject-po requires a 10+ char reject-comment; it appears as po-comment in the timeline.
6Test data & credentials
- URL
- /apps/erp
- Buyer
- buyer / Erp@123
- Manager
- manager / Erp@123
- Tax
- GST 18%
7Glossary
- PO
- Purchase order — numbered PO-2026-####
- GST
- 18% tax added to PO line totals
- Audit trail
- Timeline of submit, approve and reject events on each PO
8Watch-outs for automation
- ⚠️Two-user workflow: log out and back in as the other role within one test
- ⚠️Removing a middle line item must recalculate totals
- ⚠️Rejection needs a 10+ character comment
9Suggested test strategy
1 · Smoke
3
P1 positive and end-to-end cases — run on every build.
2 · Regression
16
All cases, incl. 5 negative and 3 edge — run before release.
3 · End-to-end
3
Full user journeys — run nightly.
Start with these smoke cases
- COREERP-01 — Raise and approve a PO
- COREERP-E2E-01 — Buyer raises PO, manager approves
- COREERP-E2E-02 — Manager rejects with comment, buyer sees it