509
0
0
509
Back to All DomainsWorkspace: SPARSS Universal Platform
DOMAIN 04 · SUPPLIER SETTLEMENT

Supplier

Products, orders, wallet, statement, reports

0% Pass
Total Tests
124
Passed
0
Failed
0
Untested
124

Supplier Auth

7 tests
TC-SUPP-AUTH-001POS

Login page renders with supplier role indicator when role=supplier in URL

TC-SUPP-AUTH-002POS

Supplier login submits to correct endpoint and stores tokens

TC-SUPP-AUTH-003NEG

Error toast displayed on failed supplier login

TC-SUPP-AUTH-004POS

Supplier registration redirects to payment link

TC-SUPP-AUTH-005POS

Toast shown when supplier registration succeeds without payment link

TC-SUPP-AUTH-006POS

Logout clears all auth state and React Query cache

TC-SUPP-AUTH-007NEG

Login as new supplier clears previous user's cached data

Supplier Dashboard

2 tests
TC-SUPP-DASH-001POS

Supplier product aggregation data loaded correctly

TC-SUPP-DASH-002POS

Chart time-filter labels render correctly

Product List & Status

8 tests
TC-SUPP-PROD-001POS

Product list loads from SUPPLIER_PRODUCTS_LIST

TC-SUPP-PROD-002NEG

Empty product list shows empty state

TC-SUPP-PROD-003POS

Product status labels and colours correct for all statuses (0, 1, 2, 3, 5)

TC-SUPP-PROD-004POS

Product status resolved from string synonyms (e.g. "deleted" → 3)

TC-SUPP-PROD-005NEG

Unrecognised status string defaults to 0

TC-SUPP-PROD-006POS

Product filter: starts with empty defaults, no active filters

TC-SUPP-PROD-007POS

Applying filters sets applied state and marks hasActive=true

TC-SUPP-PROD-008POS

Clear all resets both local and applied filter state

Add / Edit Product

5 tests
TC-SUPP-PROD-009POS

Add product POSTs to /supplier/add-product, returns productId

TC-SUPP-PROD-010POS

isDisplay normalised to 1 (truthy) and 0 (falsy) correctly

TC-SUPP-PROD-011POS

Edit product PUTs to /supplier/edit-product

TC-SUPP-PROD-012POS

Change product status (active/inactive) updates both productStatus and status fields

TC-SUPP-PROD-013POS

Soft-delete product sets status=3

Variants & Images

5 tests
TC-SUPP-PROD-014POS

Add variant wraps in array and normalises isDisplay

TC-SUPP-PROD-015POS

Edit variant merges fields with variantId

TC-SUPP-PROD-016POS

Delete variant sends productId + variantId

TC-SUPP-PROD-017POS

Save images POSTs FormData with productImages[] to product endpoint

TC-SUPP-PROD-018POS

Delete image DELETEs by productImageIds

Stock Management

20 tests
TC-SUPP-PROD-019POS

Edit Stock modal opens with variant names, original stock, totals

TC-SUPP-PROD-020NEG

Modal does not render when isOpen=false

TC-SUPP-PROD-021NEG

Modal does not render when product is null

TC-SUPP-PROD-022NEG

Review & Save disabled when no stock changed

TC-SUPP-PROD-023POS

Review & Save enabled + Modified badge shown after stock change

TC-SUPP-PROD-024POS

+10 quick-adjust increases stock by 10

TC-SUPP-PROD-025POS

+50 stacks on top of previous adjustments

TC-SUPP-PROD-026POS

"Out of Stock" resets that variant to 0

TC-SUPP-PROD-027POS

Cancel / Close (×) button closes the modal

TC-SUPP-PROD-028POS

Review & Save opens confirmation showing only changed variants

TC-SUPP-PROD-029POS

Confirm saves only modified variants via API

TC-SUPP-PROD-030NEG

Submitting with no changes short-circuits to close without confirm modal

TC-SUPP-PROD-031POS

Stock confirm modal shows +diff for increases, negative diff for decreases

TC-SUPP-PROD-032NEG

Both action buttons disabled while saving

TC-SUPP-PROD-033POS

CTA button copy changes to loading state while saving

TC-SUPP-PROD-034POS

Batch stock save writes all variants in parallel

TC-SUPP-PROD-035POS

Singular/plural toast shown for 1 vs multiple variant updates

TC-SUPP-PROD-036NEG

No API call or toast when update list is empty

TC-SUPP-PROD-037NEG

Error toast shown with server message on save failure

TC-SUPP-PROD-038NEG

isSaving reset to false after failure

Supplier Order List & Actions

10 tests
TC-SUPP-ORD-001POS

Supplier delivery orders tagged OrderType=Online Order

TC-SUPP-ORD-002POS

Supplier store pickup orders tagged OrderType=Store Pickup

TC-SUPP-ORD-003POS

"All" mode merges Online + Store Pickup orders with correct tags

TC-SUPP-ORD-004POS

Supplier can dispatch an order

TC-SUPP-ORD-005NEG

Dispatch falls back to default success message when server returns none

TC-SUPP-ORD-006POS

Supplier can cancel an order

TC-SUPP-ORD-007POS

Supplier can approve a return

TC-SUPP-ORD-008POS

Supplier can mark return as received

TC-SUPP-ORD-009POS

Store pickup completed with orderId + OTP

TC-SUPP-ORD-010NEG

Order detail disabled when orderId not provided

Profile

5 tests
TC-SUPP-PROF-001POS

Supplier profile loads with correct role

TC-SUPP-PROF-002POS

Supplier role accepts any gender value in profile schema

TC-SUPP-PROF-003NEG

Invalid email / Aadhaar / PAN rejected

TC-SUPP-PROF-004POS

Profile update invalidates cache

TC-SUPP-PROF-005POS

Profile photo upload updates user record

Change Password

3 tests
TC-SUPP-PWD-001POS

Supplier password changed via supplier endpoint

TC-SUPP-PWD-002NEG

New password matching old password rejected

TC-SUPP-PWD-003POS

Server message displayed on success

Supplier Wallet

5 tests
TC-SUPP-WLLT-001POS

Supplier wallet logs load from supplier endpoint

TC-SUPP-WLLT-002POS

Supplier wallet balance loaded

TC-SUPP-WLLT-003NEG

Balance returns 0 when walletAmt missing

TC-SUPP-WLLT-004POS

Transfer button hidden for supplier on wallet page

TC-SUPP-WLLT-005POS

Wallet stats show credited (settlement) + withdrawals (debited)

Supplier Wallet Table

5 tests
TC-SUPP-WLLT-006POS

Supplier columns: Commission, TDS, TCS, Shipping, Net Amount, Balance

TC-SUPP-WLLT-007POS

Net Amount column labelled "Net Amount" for supplier

TC-SUPP-WLLT-008POS

TDS cell shows percentage when TDSPercentage set

TC-SUPP-WLLT-009POS

TCS cell shows percentage when TCSPercentage set

TC-SUPP-WLLT-010NEG

Commission/TDS/TCS/Shipping default to ₹0 when fields null

Expanded Row & Mobile Card

8 tests
TC-SUPP-WLLT-011POS

Expanded row shows parsed description + TDS/TCS percentages

TC-SUPP-WLLT-012NEG

Description row hidden when description reduces to "---"

TC-SUPP-WLLT-013NEG

TDS/TCS shown without % suffix when percentage fields null

TC-SUPP-WLLT-014NEG

GST defaults to 0% when GSTPercentage absent

TC-SUPP-WLLT-015POS

Mobile card shows Commission label (not Txn Charges)

TC-SUPP-WLLT-016POS

Commission breakdown info button shown when hasBreakdown is true

TC-SUPP-WLLT-017NEG

Commission defaults to ₹0 on mobile card when field null

TC-SUPP-WLLT-018POS

Amount Breakdown modal shows all components + TDS + net

Supplier Withdrawals

10 tests
TC-SUPP-WITH-001POS

Supplier withdrawal list loads from /supplier/withdrawals

TC-SUPP-WITH-002POS

Supplier withdrawal request submitted to /supplier/withdrawal-request

TC-SUPP-WITH-003NEG

"Not found" / "no data" errors return empty list

TC-SUPP-WITH-004NEG

Auth/server errors are rethrown

TC-SUPP-WITH-005POS

Withdrawal amount within balance and > 0 accepted

TC-SUPP-WITH-006NEG

Amount of 0 or negative rejected

TC-SUPP-WITH-007NEG

Amount exceeding available balance rejected

TC-SUPP-WITH-008NEG

Amount over 8 characters rejected

TC-SUPP-WITH-009NEG

Empty amount field rejected

TC-SUPP-WITH-010POS

Net credited amount is null for non-dealer (supplier gets full amount)

Account Statement

5 tests
TC-SUPP-STMT-001POS

Account statement loads for selected date range

TC-SUPP-STMT-002POS

Numeric fields normalised correctly from API response

TC-SUPP-STMT-003POS

String numeric values coerced to numbers

TC-SUPP-STMT-004NEG

Zero-filled response returned on API error (no crash)

TC-SUPP-STMT-005NEG

Empty statement shown while no date range selected

TDS Reports Page

9 tests
TC-SUPP-TDS-001POS

TDS rows render with formatted withdrawal ID and amount

TC-SUPP-TDS-002POS

Stat cards show total / paid / unpaid TDS correctly

TC-SUPP-TDS-003POS

Wallet Transfer and Withdrawal type badges visible

TC-SUPP-TDS-004POS

PAID / UNPAID status badges render correctly

TC-SUPP-TDS-005POS

Search by "paid" filters out unpaid rows

TC-SUPP-TDS-006NEG

Empty state shown with API message when no records

TC-SUPP-TDS-007NEG

Error state shown when fetch fails

TC-SUPP-TDS-008NEG

TDS % defaults to 5% when field absent

TC-SUPP-TDS-009NEG

Dash fallback when withdrawal_id and id both missing

Supplier Pending Orders

8 tests
TC-SUPP-PO-001POS

Supplier pending orders loaded with total amount

TC-SUPP-PO-002POS

Orders normalised from PascalCase and snake_case field variants

TC-SUPP-PO-003NEG

Total falls back to sum of items when TotalPendingAmount is missing/zero

TC-SUPP-PO-004NEG

Synthetic orderUUID generated when missing from API

TC-SUPP-PO-005NEG

Default values applied: VariantName="N/A", StoreType="Online Order", status="Pending"

TC-SUPP-PO-006NEG

Non-numeric keys ignored when extracting orders

TC-SUPP-PO-007NEG

Empty response returned on API error (no crash)

TC-SUPP-PO-008NEG

Stable empty array returned while loading

Supplier Bank Accounts

4 tests
TC-SUPP-BANK-001POS

Supplier bank accounts loaded from supplier endpoint

TC-SUPP-BANK-002POS

Public bank list cached locally

TC-SUPP-BANK-003POS

IFSC uppercased, primary flag coerced

TC-SUPP-BANK-004NEG

Corrupt cache ignored and data refetched

Contact & Site Info

5 tests
TC-SUPP-SUPP-001POS

Valid contact form submission accepted

TC-SUPP-SUPP-002NEG

Name too short rejected

TC-SUPP-SUPP-003NEG

Message under 10 characters rejected

TC-SUPP-SUPP-004POS

Site info fetched and cached

TC-SUPP-SUPP-005POS

Site info not re-fetched when already cached