Kulcare Docs
Test plansClinic app

Test Plan: Clinic App - Invite Flow

Module: Clinic App - Invite Flow URL: https://practice-stg-new.kulcare.com/account/users Status: ✅ Complete (Tested 2026-06-11)


Test Data Requirements

TypeDataPurpose
Doctor ANew phone, valid emailTest invite creation
Staff ANew phone, valid emailTest staff invite
Admin UserOwner/Admin roleTest permission checks
Regular UserStaff/Doctor roleTest permission restrictions

Test Cases

Doctor Invite - Admin Side

#Test CasePriorityStepsExpectedResult
1Add Doctor - Complete FlowP0Fill form → SendSMS sent, invite appears✅ Pass
2Add Doctor - Phone OnlyP0Enter phone → SendInvite created✅ Pass
3Add Doctor - With MessageP0Add personal message → SendMessage in SMS✅ Pass
4View Pending InvitesP0Go to invites listPending shown✅ Pass
5View Invite DetailsP0Click on inviteShows details✅ Pass
6Cancel Pending InviteP0Cancel → ConfirmInvite cancelled✅ Pass
7Empty First NameP0Leave blank → SendError shown✅ Pass
8Empty Last NameP0Leave blank → SendError shown✅ Pass
9Empty PhoneP0Leave blank → SendError shown✅ Pass
10Invalid Phone FormatP0Enter lettersError shown✅ Pass
11Invalid Email FormatP0Enter invalid@Error shown✅ Pass
12Whitespace-Only NamesP1Enter " "Should reject❌ FAIL
13Cancel Non-Pending InviteP1Try to cancel acceptedError shown✅ Pass
14Invite to Non-Owner/AdminP1Staff tries to invite adminPermission error✅ Pass

Doctor Invite - User Side

#Test CasePriorityStepsExpectedResult
15Accept - New User (Pre-filled)P0Open link → AcceptForm pre-filled✅ Pass
16Accept - Existing UserP0Open link → AcceptRole added✅ Pass
17View Pending InvitesP0Go to invitesShows all✅ Pass
18Decline InviteP0Decline → ConfirmStatus updated✅ Pass
19View Invite DetailsP0Click inviteShows facility✅ Pass
20Expired InviteP1Open expired linkError shown✅ Pass
21Already Accepted InviteP1Open already acceptedError shown✅ Pass
22Invite for Different UserP1Phone mismatchError shown✅ Pass
23Phone MismatchP1Different phoneError shown✅ Pass
24Accept Without AuthP1Try without logging inRedirect to login✅ Pass

Staff Invite - Admin Side

#Test CasePriorityStepsExpectedResult
25Add Staff - Complete FlowP0Fill form → SendSMS sent✅ Pass
26Add Staff - Role SelectionP0Select role → SendRole assigned✅ Pass
27Add Staff - With MessageP0Add message → SendMessage in SMS✅ Pass
28View Pending Staff InvitesP0Go to staff invitesShows pending✅ Pass
29Cancel Staff InviteP0Cancel → ConfirmInvite cancelled✅ Pass
30Empty PhoneP0Leave blank → SendError shown✅ Pass
31Empty Staff RoleP0Leave blank → SendError shown✅ Pass
32Invalid Phone FormatP0Enter lettersError shown✅ Pass
33Invalid Email FormatP0Enter invalid@Error shown✅ Pass
34Whitespace-Only NamesP1Enter " "Should reject❌ FAIL
35Staff Cannot Invite AdminP0Staff tries to invite adminPermission error✅ Pass
36Admin Cannot Invite OwnerP0Admin tries to invite ownerPermission error✅ Pass
37Owner Can Invite All RolesP0Owner invites any roleAll created✅ Pass

Staff Invite - User Side

#Test CasePriorityStepsExpectedResult
38Accept Staff - New User (Pre-filled)P0Open link → AcceptForm pre-filled✅ Pass
39Accept Staff - Existing UserP0Open link → AcceptRole added✅ Pass
40Decline Staff InviteP0Decline → ConfirmStatus updated✅ Pass
41Expired Staff InviteP1Open expired linkError shown✅ Pass
42Accept Staff for Different UserP1Try to accept as different userError shown✅ Pass

SMS/Notification

#Test CasePriorityStepsExpectedResult
43SMS on Doctor InviteP0Send doctor inviteSMS received✅ Pass
44SMS on Staff InviteP0Send staff inviteSMS received✅ Pass
45Personal Message in SMSP1Add message → SendMessage in SMS✅ Pass

Multi-Clinic Invite Scoping

#Test CasePriorityStepsExpectedResult
46Invite from Clinic AP0Invite from Clinic AUser added ONLY to Clinic A✅ Pass
47Admin with multiple clinicsP0Invite from specific clinicCorrect clinic scoped✅ Pass
48User accepts inviteP0Accept inviteAppears ONLY in that clinic✅ Pass
49User cannot see other clinicsP0Accept → Check clinicsOther clinics not visible✅ Pass

Bugs Found

Bug #DescriptionSeverityStatus
18Active practitioner API missing phone number🟠 MediumOpen
19Backend validation error not displayed properly🟡 HighOpen
20Whitespace-only first/last name allowed🟠 MediumOpen
21Practitioner invite sent to existing patient🟡 HighOpen
22Cancelled invites not visible in admin UI🟠 MediumOpen
23Duplicate invite with same email in same clinic🟠 MediumOpen
24Invite sent to registered email🔴 CriticalOpen
25Invite modal form state not reset🟠 MediumOpen
26Invite to active user🔴 CriticalOpen

Test Execution Checklist

  • TC-1 to TC-49

Test Plan Status: ✅ Complete Tested: 2026-06-11 Session File: ../test-reports/sessions/05-clinic-app-invite-flow.md

On this page