Test Cases: Approval Workflow & Prospects

Module: Membership & Profiles - Approval Workflow

Two distinct approval paths — don't confuse them:

Endpoints (mounted at /api/membership):

Frontend: member detail (inline Approve/Reject) in components/members/MemberDetailHeader.tsx; prospect pipeline pages/AdminProspectsPage.tsx (/admin/prospects). Approval-workflow settings (require-approval, approver roles, min events, signup notifications): /admin/members/settings?tab=workflow (legacy /admin/settings/approval-workflow redirects).

Prerequisites

Test Cases

TC-APP-01: View Pending Members

StepActionExpected Result
1Go to Members → All MembersPending tab (/admin/members?tab=pending).Members with status PENDING_APPROVAL are listed.
2Verify applicant details (name, date applied).Correct.

TC-APP-02: Approve a Pending Member

StepActionExpected Result
1Open a PENDING_APPROVAL member → click inline Approve.POST .../members/:id/approve. Status → ACTIVE (or PENDING_PAYMENT + dues invoice if autoCreateDuesInvoice is on). Role PENDING_MEMBERMEMBER. Approval email sent.

TC-APP-03: Reject a Pending Member

StepActionExpected Result
1Open a PENDING_APPROVAL member → inline Reject → type a reason → Confirm Reject.POST .../members/:id/reject. Status → REJECTED. Rejection email (with reason) sent.

TC-APP-04: Approve an Applicant via Prospects (application path)

StepActionExpected Result
1Go to Prospects (/admin/prospects). Find an APPLIED applicant (e.g. Miguel Fernandez / pending@demo.membervu.com).Applicant appears in the pipeline (APPLIED / Review stage).
2Click Move to Review (optional), then Approve → the Approve Application modal opens (select a membership type; optionally create a dues invoice). Confirm.POST .../admin/applications/:id/approve. prospectStatus → APPROVED; member provisioned per membership type.
3(Negative) Try the member-approve endpoint on this same applicant: POST /api/membership/members/:id/approve.Rejected — "only PENDING_APPROVAL members can be approved" (status is GUEST_ATTENDEE).

TC-APP-05: Bulk Approve / Reject

StepActionExpected Result
1From the Pending tab, select multiple pending members → bulk Approve / Reject.POST .../members/bulk-approve / bulk-reject (guard requireApproverRole). Statuses update accordingly.

TC-APP-06: Approval-Workflow Settings

StepActionExpected Result
1Go to Member Settings → Workflow tab (/admin/members/settings?tab=workflow).Settings: require-approval toggle, approver roles, min events for invitation, signup notifications (#186 — enable + recipients).