Test Session
Overall Progress0 / 156 steps completed
0
Pass
0
Fail
156
Remaining
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 1.1.1 | Navigate to the Login page | Login form renders without errors | ||
| 1.1.2 | Submit with empty fields | Validation error shown, no redirect | ||
| 1.1.3 | Submit with incorrect password | "Invalid credentials" error shown | ||
| 1.1.4 | Submit with correct staff credentials | Redirect to staff dashboard | ||
| 1.1.5 | Submit with correct admin credentials | Redirect to admin dashboard | ||
| 1.1.6 | After login, inspect session cookie for HttpOnly flag | HttpOnly = true in browser dev tools | ||
| 1.1.7 | Navigate to login page while already logged in | Redirect to dashboard (no login form shown) |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 1.2.1 | Click Logout | Session destroyed, redirect to login page | ||
| 1.2.2 | After logout, navigate to dashboard URL directly | Redirect to login page (not dashboard) |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 1.3.1 | Navigate to Reset Password page | Form renders correctly | ||
| 1.3.2 | Submit with unregistered email | "Email not found" or generic message shown | ||
| 1.3.3 | Submit with registered email | Success message shown; reset email sent | ||
| 1.3.4 | Click reset link from email | Password reset form shown with token in URL | ||
| 1.3.5 | Submit new password on reset form | Password updated; redirect to login | ||
| 1.3.6 | Try to reuse the same reset link | "Token expired or invalid" error |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 1.4.1 | Navigate to Change Password page | Form renders correctly | ||
| 1.4.2 | Submit with wrong current password | Error message shown | ||
| 1.4.3 | Submit with new passwords that do not match | Validation error shown | ||
| 1.4.4 | Submit with correct current password and matching new passwords | Success message; can log in with new password |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 1.5.1 | Navigate to Signup page | Registration form renders | ||
| 1.5.2 | Submit with missing required fields | Validation errors shown | ||
| 1.5.3 | Submit with an email already in use | "Email already registered" error | ||
| 1.5.4 | Submit valid registration | Success message; account appears as "Pending" in Staff Management | ||
| 1.5.5 | Attempt to log in before approval | "Account pending approval" or access denied message |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 2.1.1 | Log in as a staff member and view dashboard | Leave balance cards display correct values | ||
| 2.1.2 | Verify Annual Leave balance matches what admin has set | Correct days shown | ||
| 2.1.3 | Verify Sick Leave balance is displayed | Correct days shown | ||
| 2.1.4 | Recent leave requests section shows last 5 requests | Correct history shown |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 2.2.1 | Navigate to Leave Request form | Form renders with leave type dropdown | ||
| 2.2.2 | Submit with no dates selected | Validation error shown | ||
| 2.2.3 | Submit with end date before start date | Validation error shown | ||
| 2.2.4 | Submit a valid Annual Leave request | Success message; request appears in Leave History with "Pending" status | ||
| 2.2.5 | Submit a valid Sick Leave request | Success message; request appears in Leave History | ||
| 2.2.6 | Submit a request that exceeds available balance | Error message shown; request not created | ||
| 2.2.7 | Submit a request overlapping an existing approved request | Error or warning shown |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 2.3.1 | Navigate to Leave History page | All past and current requests listed | ||
| 2.3.2 | Filter by status (Pending / Approved / Rejected) | List filters correctly | ||
| 2.3.3 | Click "View Details" on a request | Modal opens with full request details | ||
| 2.3.4 | Cancel a Pending request | Status changes to Cancelled; balance restored | ||
| 2.3.5 | Attempt to cancel an Approved request | Cancel button not shown or action blocked |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 2.4.1 | Navigate to Leave Balance page | Balances shown per leave type | ||
| 2.4.2 | Verify balances match the dashboard cards | Values are consistent |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 3.1.1 | Navigate to Calendar page | Calendar renders in month view by default | ||
| 3.1.2 | Approved leave requests appear as coloured chips on correct dates | Chips shown on correct days | ||
| 3.1.3 | Hover over a leave chip | Tooltip shows staff name and leave period (e.g., "John Smith | Mar 5 โ Mar 10") | ||
| 3.1.4 | Day with more than 3 people on leave shows "+N more" chip | "+N more" chip appears; hover shows all hidden entries | ||
| 3.1.5 | Click the Previous/Next navigation arrows | Calendar navigates to previous/next month | ||
| 3.1.6 | Click "Today" button | Calendar returns to current month |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 3.2.1 | Switch to Week view | Calendar renders week view correctly | ||
| 3.2.2 | Leave chips appear on correct days | Correct staff and dates shown | ||
| 3.2.3 | Hover over a chip | Tooltip shows staff name and leave period |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 3.3.1 | Switch to List view | Tabular list of leave entries renders | ||
| 3.3.2 | Leave Type column shows correct type (not hardcoded "Annual") | Correct leave type shown per row | ||
| 3.3.3 | Click a row in list view | Leave request details modal opens |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 4.1.1 | Navigate to Team Requests | All staff leave requests listed | ||
| 4.1.2 | Filter by status (Pending / Approved / Rejected) | List filters correctly | ||
| 4.1.3 | Click "View Details" on any request | Modal opens with full request details | ||
| 4.1.4 | Pending requests show Approve and Reject buttons | Both buttons visible | ||
| 4.1.5 | Approved requests show Reject and Move to Pending buttons | Both buttons visible; no Approve button | ||
| 4.1.6 | Rejected requests show Approve and Move to Pending buttons | Both buttons visible; no Reject button |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 4.2.1 | Click Approve on a Pending request | Status changes to Approved; leave balance deducted | ||
| 4.2.2 | Click Approve on a Rejected request | Status changes to Approved; leave balance deducted | ||
| 4.2.3 | After approving, verify staff member's balance is reduced by correct number of days | Balance reduced correctly |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 4.3.1 | Click Reject on a Pending request | Status changes to Rejected; balance not deducted | ||
| 4.3.2 | Click Reject on an Approved request | Status changes to Rejected; leave balance restored | ||
| 4.3.3 | After rejecting an approved request, verify staff member's balance is restored | Balance restored correctly |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 4.4.1 | Click "Move to Pending" on an Approved request | Status changes to Pending; leave balance restored | ||
| 4.4.2 | Click "Move to Pending" on a Rejected request | Status changes to Pending | ||
| 4.4.3 | After moving an approved request to pending, verify balance is restored | Balance restored correctly |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 5.1.1 | Navigate to Staff Management | All active staff listed with correct details | ||
| 5.1.2 | Pending signups section shows unapproved registrations | Pending accounts listed separately | ||
| 5.1.3 | Click on a staff member row to view details | Details panel or modal opens with all fields including Position |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 5.2.1 | Click "Add Staff" button | Add Staff modal opens | ||
| 5.2.2 | Verify Position field is present in the form | Position input field visible | ||
| 5.2.3 | Submit with missing required fields | Validation errors shown | ||
| 5.2.4 | Submit with duplicate email | "Email already exists" error | ||
| 5.2.5 | Submit valid staff details including Position | Staff created; appears in list with correct Position |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 5.3.1 | Click Edit on a staff member | Edit Staff modal opens pre-populated with all fields | ||
| 5.3.2 | Verify Position field is pre-populated | Position field shows current value | ||
| 5.3.3 | Change the Position field and save | Position updated and visible in staff details | ||
| 5.3.4 | Change the Department and save | Department updated correctly | ||
| 5.3.5 | Change the Role (Staff / Manager / Admin) and save | Role updated; user has correct permissions after re-login |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 5.4.1 | Click Approve on a pending signup | Account activated; staff can now log in | ||
| 5.4.2 | After approval, staff member appears in active staff list | Staff visible in main list | ||
| 5.4.3 | Approved staff member can log in successfully | Login succeeds |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 5.5.1 | Click Delete on a staff member | Confirmation prompt shown | ||
| 5.5.2 | Confirm deletion | Staff removed; their leave requests and balances also removed (FK cascade) |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 6.1.1 | Navigate to Reports page | Page loads without errors | ||
| 6.1.2 | "Total Staff" card is NOT present | Card removed as requested | ||
| 6.1.3 | Total Leave Requests card shows correct count | Count matches actual requests in DB | ||
| 6.1.4 | Pending Requests card shows correct count | Count matches pending requests | ||
| 6.1.5 | Approved Requests card shows correct count | Count matches approved requests |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 6.2.1 | Top Leave Takers section displays data | Staff names and leave counts shown (not empty) | ||
| 6.2.2 | Staff are ranked in descending order of leave taken | Highest leave taker shown first | ||
| 6.2.3 | Filter by date range and verify results update | Filtered results shown correctly |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 6.3.1 | Department Breakdown section displays data | All departments shown with leave counts | ||
| 6.3.2 | Counts are accurate per department | Matches actual data |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 6.4.1 | Leave Type Distribution chart renders | Chart visible with correct leave types | ||
| 6.4.2 | Chart data matches the actual leave requests | Annual, Sick, Other percentages are correct |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 7.1.1 | Navigate to Departments page | All departments listed | ||
| 7.1.2 | Department name, code, and manager shown | Correct details displayed |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 7.2.1 | Click "Add Department" | Add Department modal opens | ||
| 7.2.2 | Submit with missing name | Validation error shown | ||
| 7.2.3 | Submit with duplicate department code | Error shown | ||
| 7.2.4 | Submit valid department | Department created and appears in list |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 7.3.1 | Click Edit on a department | Edit modal opens pre-populated | ||
| 7.3.2 | Change name and save | Name updated in list | ||
| 7.3.3 | Assign a manager and save | Manager shown in department row |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 7.4.1 | Click Delete on a department | Confirmation prompt shown | ||
| 7.4.2 | Confirm deletion | Department removed; staff in that department have department_id set to NULL (not deleted) |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 8.1.1 | Navigate to Leave Policies page | All policies listed | ||
| 8.1.2 | Default policy is marked | Default indicator visible |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 8.2.1 | Click "Add Policy" | Add Policy modal opens | ||
| 8.2.2 | Submit with missing name | Validation error shown | ||
| 8.2.3 | Submit valid policy with annual and sick day allocations | Policy created and appears in list |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 8.3.1 | Click Edit on a policy | Edit modal opens pre-populated | ||
| 8.3.2 | Change annual days and save | Updated value shown in list | ||
| 8.3.3 | Assign policy to a staff member | Staff member's balance reflects new policy |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 8.4.1 | Delete a policy that has staff assigned | Staff members' policy_id set to NULL (not deleted) | ||
| 8.4.2 | Delete an unused policy | Policy removed from list |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 9.1.1 | Navigate to Settings โ Email | Email settings form renders | ||
| 9.1.2 | Enter SMTP credentials and save | Success message shown | ||
| 9.1.3 | Reload the page | SMTP host, port, and username are retained; password field is blank (encrypted in DB) | ||
| 9.1.4 | Save without entering a new password | Existing encrypted password is preserved (not overwritten with blank) | ||
| 9.1.5 | Send a test email | Email received at the test address |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 9.2.1 | Navigate to Settings โ Leave Policies | Policy settings render | ||
| 9.2.2 | Change a setting and save | Setting persists after page reload |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 9.3.1 | Navigate to Settings โ Notifications | Notification toggles render | ||
| 9.3.2 | Toggle a notification on/off and save | Setting persists after page reload |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 9.4.1 | Navigate to Settings โ Appearance | Appearance settings render | ||
| 9.4.2 | Upload a logo | Logo appears in the plugin header | ||
| 9.4.3 | Change accent colour and save | Colour applied to UI elements |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 10.1.1 | Navigate to Profile page as staff | Profile details shown (name, email, department, position) | ||
| 10.1.2 | Position field is visible | Position shown correctly |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 10.2.1 | Edit name and save | Name updated; reflected in header/dashboard | ||
| 10.2.2 | Edit phone number and save | Phone number updated |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 11.1 | While logged out, POST to admin-ajax.php with action=leave_manager_approve_request | Response: authentication error (not success) | ||
| 11.2 | While logged in as staff (non-admin), call leave_manager_clear_logs | Response: permission denied | ||
| 11.3 | While logged in as staff, call leave_manager_save_email_settings | Response: permission denied | ||
| 11.4 | Navigate directly to a plugin PHP file URL (e.g., /wp-content/plugins/leave-manager/includes/class-admin-ajax-handler.php) | Blank page or redirect (ABSPATH guard exits silently) | ||
| 11.5 | Enter <script>alert(1)</script> as a staff name and save | Script tag is escaped in all display locations; no alert fires |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| 12.1 | Test all pages in Chrome | No layout breaks or JS errors in console | ||
| 12.2 | Test all pages in Firefox | No layout breaks or JS errors in console | ||
| 12.3 | Test dashboard on mobile (375px width) | Layout is responsive; no horizontal scroll | ||
| 12.4 | Test calendar on mobile | Calendar is usable; chips are readable | ||
| 12.5 | Test modals on mobile | Modals open and close correctly; form fields are accessible |
| # | Action / Step | Expected Result | Result | Comment |
|---|---|---|---|---|
| R1 | Approve a request, then click "Move to Pending" | Status = Pending; balance restored | ||
| R2 | Reject a request, then click "Approve" | Status = Approved; balance deducted | ||
| R3 | Add a new staff member with a Position | Position saved and visible in staff details | ||
| R4 | Edit an existing staff member's Position | Position updated correctly | ||
| R5 | Register via signup form, then approve in Staff Management | Staff can log in after approval | ||
| R6 | Hover over a leave chip on the calendar | Tooltip shows name and date range | ||
| R7 | Switch to list view on calendar | Leave Type column shows correct type (not "Annual" for all) | ||
| R8 | Navigate to Reports page | Top Leave Takers section shows data | ||
| R9 | Save SMTP settings, reload page | Password field is blank but email still sends correctly | ||
| R10 | Approve a request, then reject it | Balance is fully restored to pre-approval value |
Summary by Section
| Section | Total | Pass | Fail | Remaining | Progress |
|---|---|---|---|---|---|
| ๐ Authentication โ Login | 7 | 0 | 0 | 7 | 0% |
| ๐ช Authentication โ Logout | 2 | 0 | 0 | 2 | 0% |
| ๐ Authentication โ Password Reset | 6 | 0 | 0 | 6 | 0% |
| ๐ Authentication โ Change Password | 4 | 0 | 0 | 4 | 0% |
| ๐ Authentication โ Employee Self-Registration | 5 | 0 | 0 | 5 | 0% |
| ๐ Staff Dashboard โ Overview | 4 | 0 | 0 | 4 | 0% |
| ๐ค Staff Dashboard โ Submit Leave Request | 7 | 0 | 0 | 7 | 0% |
| ๐ Staff Dashboard โ Leave History | 5 | 0 | 0 | 5 | 0% |
| โ๏ธ Staff Dashboard โ Leave Balance | 2 | 0 | 0 | 2 | 0% |
| ๐ Calendar โ Month View | 6 | 0 | 0 | 6 | 0% |
| ๐ Calendar โ Week View | 3 | 0 | 0 | 3 | 0% |
| ๐ Calendar โ List View | 3 | 0 | 0 | 3 | 0% |
| ๐๏ธ Team Leave Requests โ Viewing | 6 | 0 | 0 | 6 | 0% |
| โ Team Leave Requests โ Approving | 3 | 0 | 0 | 3 | 0% |
| โ Team Leave Requests โ Rejecting | 3 | 0 | 0 | 3 | 0% |
| ๐ Team Leave Requests โ Move to Pending | 3 | 0 | 0 | 3 | 0% |
| ๐ฅ Staff Management โ Viewing | 3 | 0 | 0 | 3 | 0% |
| โ Staff Management โ Adding Staff | 5 | 0 | 0 | 5 | 0% |
| โ๏ธ Staff Management โ Editing Staff | 5 | 0 | 0 | 5 | 0% |
| ๐ข Staff Management โ Approving Signups | 3 | 0 | 0 | 3 | 0% |
| ๐๏ธ Staff Management โ Deleting Staff | 2 | 0 | 0 | 2 | 0% |
| ๐ Reports โ Summary Metrics | 5 | 0 | 0 | 5 | 0% |
| ๐ Reports โ Top Leave Takers | 3 | 0 | 0 | 3 | 0% |
| ๐ข Reports โ Department Breakdown | 2 | 0 | 0 | 2 | 0% |
| ๐ฅง Reports โ Leave Type Distribution | 2 | 0 | 0 | 2 | 0% |
| ๐๏ธ Departments โ Viewing | 2 | 0 | 0 | 2 | 0% |
| ๐๏ธ Departments โ Adding | 4 | 0 | 0 | 4 | 0% |
| ๐๏ธ Departments โ Editing | 3 | 0 | 0 | 3 | 0% |
| ๐๏ธ Departments โ Deleting | 2 | 0 | 0 | 2 | 0% |
| ๐ Leave Policies โ Viewing | 2 | 0 | 0 | 2 | 0% |
| ๐ Leave Policies โ Adding | 3 | 0 | 0 | 3 | 0% |
| ๐ Leave Policies โ Editing | 3 | 0 | 0 | 3 | 0% |
| ๐๏ธ Leave Policies โ Deleting | 2 | 0 | 0 | 2 | 0% |
| ๐ง Settings โ Email / SMTP | 5 | 0 | 0 | 5 | 0% |
| โ๏ธ Settings โ Leave Policies | 2 | 0 | 0 | 2 | 0% |
| ๐ Settings โ Notifications | 2 | 0 | 0 | 2 | 0% |
| ๐จ Settings โ Appearance | 3 | 0 | 0 | 3 | 0% |
| ๐ค Profile โ Viewing | 2 | 0 | 0 | 2 | 0% |
| โ๏ธ Profile โ Editing | 2 | 0 | 0 | 2 | 0% |
| ๐ก๏ธ Security Spot Checks | 5 | 0 | 0 | 5 | 0% |
| ๐ฑ Cross-Browser & Responsive | 5 | 0 | 0 | 5 | 0% |
| ๐ Regression Checks | 10 | 0 | 0 | 10 | 0% |
Leave Manager v1.0.102 ยท 156 test cases ยท Progress auto-saved to browser