Test Cases: Profile Management

Module: Membership & Profiles - Profile Management

Endpoints (mounted at /api/membership):

Frontend: member self → /account/profile (pages/account/ProfileTab.tsx); admin full edit → /admin/members/:id/edit (pages/AdminEditMemberPage.tsx). Legacy /profile redirects to /account/profile.

Prerequisites

Test Cases

TC-PROF-01: View Own Profile

StepActionExpected Result
1Log in as Maria Cruz → sidebar My AccountProfile tab (/account/profile).Profile loads. GET /api/membership/members/me.
2Verify displayed data.First/last/middle name, email, phone, address, profession/company, socials match the member record.
3Privacy.No sensitive fields (password hash, internal IDs) exposed.

TC-PROF-02: Update Personal Details (incl. international phone)

StepActionExpected Result
1On /account/profile, edit Phone (uses the international PhoneInput — country selector + number), Address, LinkedIn.Fields editable; "Save Changes" enables when the form is dirty.
2Use a US/intl number (e.g. +1 202 555 0142). Click Save Changes.PATCH .../members/me200. The intl phone persists (#182) on reload.

TC-PROF-03: Upload Avatar

StepActionExpected Result
1On /account/profile, in the Profile Photo card click "Upload Photo". Pick a JPG/PNG.A crop modal opens; confirm.
2Save.PATCH .../members/me/avatar. Toast "Profile photo updated!". The image displays immediately and persists — stored as an S3 key, not an inline data URI (#199 fix).

TC-PROF-04: Avatar Validation

StepActionExpected Result
1Try an oversized image (the UI hint is "JPG or PNG, max 5MB"); also try a non-image / .svg.Rejected. (Server also normalizes only jpeg/png/gif/webp ≤2MB; SVG is blocked — see security #127.)

TC-PROF-05: Admin Edits a Member Profile + Joined Date (#184)

StepActionExpected Result
1As ADMIN, All Members → open a member → "Edit Profile" (/admin/members/:id/edit).Full edit form loads.
2In "Membership Information", change "Member Since (Joined Date)" (date ≤ today). Save.PATCH .../members/:id with joinedAt. Saved; change written to the member audit log.