# 1. Shared Goal Setting — Test Cases

User Type: **Super Administrator**
Source: *Mi Digital Academy - Education CRM Features Document*
Spec: shared_goal_setting.md — every feature, sub-feature, and rule covered

## Test Execution Policy

- Zero tolerance: any deviation from the documented behavior is a defect.
- Every failed test is logged with a Bug ID, the feature, the sub-feature, the expected vs actual result, and the severity; 100% of bugs are fixed before the group passes.
- 100% pass rate is required for the group to be marked complete.

## Coverage Matrix

| Feature | Sub-feature / Rule | Test IDs |
|---------|--------------------|----------|
| 1.1 Goal Template Library | Template creation | TC-SA-PS-01-001 |
| 1.1 Goal Template Library | Template categories | TC-SA-PS-01-002 |
| 1.1 Goal Template Library | Template parameters | TC-SA-PS-01-003 |
| 1.1 Goal Template Library | Template enablement | TC-SA-PS-01-004 |
| 1.1 Goal Template Library | Template gallery | TC-SA-PS-01-005 |
| 1.1 Goal Template Library | Rule: a creation requires a name and a target | TC-SA-PS-01-006 |
| 1.1 Goal Template Library | Rule: a template in use cannot be deleted | TC-SA-PS-01-007 |
| 1.1 Goal Template Library | Rule: template actions are audit-logged | TC-SA-PS-01-008 |
| 1.2 Collaborative Goal Creation | Goal initiation | TC-SA-PS-01-009 |
| 1.2 Collaborative Goal Creation | Goal co-editing | TC-SA-PS-01-010 |
| 1.2 Collaborative Goal Creation | Goal agreement | TC-SA-PS-01-011 |
| 1.2 Collaborative Goal Creation | Goal assignment | TC-SA-PS-01-012 |
| 1.2 Collaborative Goal Creation | Goal status | TC-SA-PS-01-013 |
| 1.2 Collaborative Goal Creation | Rule: a goal without agreement cannot be activated | TC-SA-PS-01-014 |
| 1.2 Collaborative Goal Creation | Rule: goal actions are audit-logged | TC-SA-PS-01-015 |
| 1.3 Goal Progress Tracking | Progress updates | TC-SA-PS-01-016 |
| 1.3 Goal Progress Tracking | Progress visibility | TC-SA-PS-01-017 |
| 1.3 Goal Progress Tracking | Progress milestones | TC-SA-PS-01-018 |
| 1.3 Goal Progress Tracking | Progress alerts | TC-SA-PS-01-019 |
| 1.3 Goal Progress Tracking | Progress history | TC-SA-PS-01-020 |
| 1.3 Goal Progress Tracking | Rule: an update outside the goal window is rejected | TC-SA-PS-01-021 |
| 1.3 Goal Progress Tracking | Rule: tracking actions are audit-logged | TC-SA-PS-01-022 |
| 1.4 Milestone Celebration | Celebration trigger | TC-SA-PS-01-023 |
| 1.4 Milestone Celebration | Celebration message | TC-SA-PS-01-024 |
| 1.4 Milestone Celebration | Celebration badge | TC-SA-PS-01-025 |
| 1.4 Milestone Celebration | Celebration sharing | TC-SA-PS-01-026 |
| 1.4 Milestone Celebration | Celebration log | TC-SA-PS-01-027 |
| 1.4 Milestone Celebration | Rule: a celebration for an unmet milestone is not triggered | TC-SA-PS-01-028 |
| 1.4 Milestone Celebration | Rule: celebration actions are audit-logged | TC-SA-PS-01-029 |
| 1.5 Parent Challenges | Challenge creation | TC-SA-PS-01-030 |
| 1.5 Parent Challenges | Challenge type | TC-SA-PS-01-031 |
| 1.5 Parent Challenges | Challenge assignment | TC-SA-PS-01-032 |
| 1.5 Parent Challenges | Challenge completion | TC-SA-PS-01-033 |
| 1.5 Parent Challenges | Challenge reward | TC-SA-PS-01-034 |
| 1.5 Parent Challenges | Rule: a challenge with no assignment is not active | TC-SA-PS-01-035 |
| 1.5 Parent Challenges | Rule: challenge actions are audit-logged | TC-SA-PS-01-036 |

### TC-SA-PS-01-001 — Template creation
**Type:** Positive
**Covers:** 1.1 → Template creation: the creation of a goal template
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, create a goal template with a name and target.
2. Save the template.
3. Observe the result and verify the full behavior: the template is created and listed.
**Expected Result:** The creation works — the template is listed, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-002 — Template categories
**Type:** Positive
**Covers:** 1.1 → Template categories: the categories of goal templates
**Preconditions:** A Super Admin account is active; a template exists.
**Steps:**
1. As a Super Admin, assign the template to a category and save.
2. Observe the result and verify the full behavior: the category is shown.
**Expected Result:** The category is set — it is shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-003 — Template parameters
**Type:** Positive
**Covers:** 1.1 → Template parameters: the parameters of the template
**Preconditions:** A Super Admin account is active; a template exists.
**Steps:**
1. As a Super Admin, set the target and duration and save.
2. Observe the result and verify the full behavior: the parameters are shown.
**Expected Result:** The parameters are set — they are shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-004 — Template enablement
**Type:** Positive
**Covers:** 1.1 → Template enablement: the template toggled active or inactive
**Preconditions:** A Super Admin account is active; a template exists.
**Steps:**
1. As a Super Admin, activate the template.
2. Observe the result and verify the full behavior: the template is available for use.
**Expected Result:** The enablement works — the template is available, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-005 — Template gallery
**Type:** Positive
**Covers:** 1.1 → Template gallery: the gallery of available goal templates
**Preconditions:** A Super Admin account is active; multiple active templates exist.
**Steps:**
1. As a Super Admin, open the template gallery.
2. Observe the result and verify the full behavior: the active templates are listed.
**Expected Result:** The gallery is shown — the templates are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-PS-01-006 — Rule: a creation requires a name and a target
**Type:** Negative
**Covers:** 1.1 → Rule: a template creation requires a name and a target
**Preconditions:** A Super Admin account is active; the target is empty.
**Steps:**
1. As a Super Admin, attempt to create the template without a target.
2. Observe the result and verify the full behavior: the creation is blocked with a validation error.
**Expected Result:** The creation is blocked — the required fields are enforced, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-007 — Rule: a template in use cannot be deleted
**Type:** Negative
**Covers:** 1.1 → Rule: a template in use cannot be deleted; it must be unassigned first
**Preconditions:** A Super Admin account is active; a template is in use.
**Steps:**
1. As a Super Admin, attempt to delete the template.
2. Observe the result and verify the full behavior: the deletion is blocked.
**Expected Result:** The deletion is blocked — the in-use protection is enforced, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-008 — Rule: template actions are audit-logged
**Type:** Positive
**Covers:** 1.1 → Audit logging of goal template library
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, create a template and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the action is recorded with the actor and timestamp.
**Expected Result:** The action is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-009 — Goal initiation
**Type:** Positive
**Covers:** 1.2 → Goal initiation: the initiation of a goal by a parent or student
**Preconditions:** A Super Admin account is active; a parent and student are linked.
**Steps:**
1. As a parent, initiate a goal.
2. Observe the result and verify the full behavior: the goal is created in draft status.
**Expected Result:** The initiation works — the goal is created, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-010 — Goal co-editing
**Type:** Positive
**Covers:** 1.2 → Goal co-editing: the co-editing of the goal by both parties
**Preconditions:** A Super Admin account is active; a goal is in draft.
**Steps:**
1. As a student, edit the goal.
2. Observe the result and verify the full behavior: the edit is reflected for both parties.
**Expected Result:** The co-editing works — the edit is reflected, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-011 — Goal agreement
**Type:** Positive
**Covers:** 1.2 → Goal agreement: the agreement of both parties on the goal
**Preconditions:** A Super Admin account is active; a goal is in draft.
**Steps:**
1. As a parent, accept the goal.
2. As a student, accept the goal.
3. Observe the result and verify the full behavior: the goal is marked agreed.
**Expected Result:** The agreement works — the goal is agreed, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-012 — Goal assignment
**Type:** Positive
**Covers:** 1.2 → Goal assignment: the assignment of the goal to the student
**Preconditions:** A Super Admin account is active; a goal is agreed.
**Steps:**
1. As a Super Admin, assign the goal to the student.
2. Observe the result and verify the full behavior: the goal is linked to the student.
**Expected Result:** The assignment works — the goal is linked, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-013 — Goal status
**Type:** Positive
**Covers:** 1.2 → Goal status: the status of the collaborative goal
**Preconditions:** A Super Admin account is active; a goal exists.
**Steps:**
1. As a Super Admin, view the goal status.
2. Observe the result and verify the full behavior: the status is shown.
**Expected Result:** The status is shown — it reflects the state, delivered exactly as documented.
**Priority:** Low

### TC-SA-PS-01-014 — Rule: a goal without agreement cannot be activated
**Type:** Negative
**Covers:** 1.2 → Rule: a goal without agreement cannot be activated
**Preconditions:** A Super Admin account is active; a goal is in draft with no agreement.
**Steps:**
1. As a Super Admin, attempt to activate the goal.
2. Observe the result and verify the full behavior: the activation is blocked.
**Expected Result:** The activation is blocked — the agreement precondition is enforced, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-015 — Rule: goal actions are audit-logged
**Type:** Positive
**Covers:** 1.2 → Audit logging of collaborative goal creation
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, assign the goal and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the action is recorded with the actor and timestamp.
**Expected Result:** The action is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-016 — Progress updates
**Type:** Positive
**Covers:** 1.3 → Progress updates: the updates to the goal progress
**Preconditions:** A Super Admin account is active; a goal is active.
**Steps:**
1. As a student, update the goal progress.
2. Observe the result and verify the full behavior: the update is recorded.
**Expected Result:** The update works — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-017 — Progress visibility
**Type:** Positive
**Covers:** 1.3 → Progress visibility: the visibility of the progress to both parties
**Preconditions:** A Super Admin account is active; a goal has progress.
**Steps:**
1. As a parent, view the goal progress.
2. Observe the result and verify the full behavior: the progress is visible.
**Expected Result:** The visibility works — the progress is visible, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-018 — Progress milestones
**Type:** Positive
**Covers:** 1.3 → Progress milestones: the milestones within the goal
**Preconditions:** A Super Admin account is active; a goal exists.
**Steps:**
1. As a Super Admin, add a milestone to the goal and save.
2. Observe the result and verify the full behavior: the milestone is listed.
**Expected Result:** The milestone is added — it is listed, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-019 — Progress alerts
**Type:** Positive
**Covers:** 1.3 → Progress alerts: the alerts on goal progress
**Preconditions:** A Super Admin account is active; a goal has a milestone.
**Steps:**
1. As a student, reach the milestone.
2. Observe the result and verify the full behavior: an alert is sent.
**Expected Result:** The alert is sent — it is delivered, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-020 — Progress history
**Type:** Positive
**Covers:** 1.3 → Progress history: the history of the goal progress
**Preconditions:** A Super Admin account is active; a goal has past updates.
**Steps:**
1. As a Super Admin, open the progress history.
2. Observe the result and verify the full behavior: the past updates are listed.
**Expected Result:** The history is shown — the updates are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-PS-01-021 — Rule: an update outside the goal window is rejected
**Type:** Negative
**Covers:** 1.3 → Rule: a progress update outside the goal window is rejected
**Preconditions:** A Super Admin account is active; the goal window has closed.
**Steps:**
1. As a student, attempt to update the goal progress.
2. Observe the result and verify the full behavior: the update is rejected.
**Expected Result:** The update is rejected — the window is enforced, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-022 — Rule: tracking actions are audit-logged
**Type:** Positive
**Covers:** 1.3 → Audit logging of goal progress tracking
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, add a milestone and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the action is recorded with the actor and timestamp.
**Expected Result:** The action is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-023 — Celebration trigger
**Type:** Positive
**Covers:** 1.4 → Celebration trigger: the trigger for a milestone celebration
**Preconditions:** A Super Admin account is active; a goal has a milestone.
**Steps:**
1. As a student, reach the milestone.
2. Observe the result and verify the full behavior: the celebration is triggered.
**Expected Result:** The trigger works — the celebration is triggered, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-024 — Celebration message
**Type:** Positive
**Covers:** 1.4 → Celebration message: the message for the celebration
**Preconditions:** A Super Admin account is active; a celebration is triggered.
**Steps:**
1. As a Super Admin, set the celebration message and save.
2. Observe the result and verify the full behavior: the message is shown.
**Expected Result:** The message is set — it is shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-025 — Celebration badge
**Type:** Positive
**Covers:** 1.4 → Celebration badge: the badge awarded for the milestone
**Preconditions:** A Super Admin account is active; a celebration is triggered.
**Steps:**
1. As a Super Admin, assign the badge and save.
2. Observe the result and verify the full behavior: the badge is awarded.
**Expected Result:** The badge is awarded — it is granted, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-026 — Celebration sharing
**Type:** Positive
**Covers:** 1.4 → Celebration sharing: the sharing of the celebration with the family
**Preconditions:** A Super Admin account is active; a celebration is triggered.
**Steps:**
1. As a Super Admin, enable the celebration sharing.
2. Observe the result and verify the full behavior: the celebration is sent to the family.
**Expected Result:** The sharing works — the celebration is sent, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-027 — Celebration log
**Type:** Positive
**Covers:** 1.4 → Celebration log: the log of the celebrations
**Preconditions:** A Super Admin account is active; celebrations have occurred.
**Steps:**
1. As a Super Admin, open the celebration log.
2. Observe the result and verify the full behavior: the past celebrations are listed.
**Expected Result:** The log is shown — the celebrations are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-PS-01-028 — Rule: a celebration for an unmet milestone is not triggered
**Type:** Negative
**Covers:** 1.4 → Rule: a celebration for an unmet milestone is not triggered
**Preconditions:** A Super Admin account is active; a milestone is not reached.
**Steps:**
1. As a student, view the goal.
2. Observe the result and verify the full behavior: no celebration is triggered.
**Expected Result:** No celebration is triggered — the milestone is unmet, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-029 — Rule: celebration actions are audit-logged
**Type:** Positive
**Covers:** 1.4 → Audit logging of milestone celebration
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, set the celebration message and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the action is recorded with the actor and timestamp.
**Expected Result:** The action is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-030 — Challenge creation
**Type:** Positive
**Covers:** 1.5 → Challenge creation: the creation of a parent challenge
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, create a challenge with a name and type.
2. Save the challenge.
3. Observe the result and verify the full behavior: the challenge is created and listed.
**Expected Result:** The creation works — the challenge is listed, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-031 — Challenge type
**Type:** Positive
**Covers:** 1.5 → Challenge type: the type of the challenge
**Preconditions:** A Super Admin account is active; a challenge exists.
**Steps:**
1. As a Super Admin, set the type to read alongside and save.
2. Observe the result and verify the full behavior: the type is shown.
**Expected Result:** The type is set — it is shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-032 — Challenge assignment
**Type:** Positive
**Covers:** 1.5 → Challenge assignment: the assignment of the challenge to a family
**Preconditions:** A Super Admin account is active; a challenge and a family exist.
**Steps:**
1. As a Super Admin, assign the challenge to the family and save.
2. Observe the result and verify the full behavior: the challenge is linked to the family.
**Expected Result:** The assignment works — the challenge is linked, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-033 — Challenge completion
**Type:** Positive
**Covers:** 1.5 → Challenge completion: the completion of the challenge
**Preconditions:** A Super Admin account is active; a challenge is assigned.
**Steps:**
1. As a family, complete the challenge.
2. Observe the result and verify the full behavior: the completion is recorded.
**Expected Result:** The completion works — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-034 — Challenge reward
**Type:** Positive
**Covers:** 1.5 → Challenge reward: the reward for completing the challenge
**Preconditions:** A Super Admin account is active; a challenge is completed.
**Steps:**
1. As a Super Admin, grant the reward.
2. Observe the result and verify the full behavior: the reward is granted.
**Expected Result:** The reward is granted — it is awarded, delivered exactly as documented.
**Priority:** Medium

### TC-SA-PS-01-035 — Rule: a challenge with no assignment is not active
**Type:** Negative
**Covers:** 1.5 → Rule: a challenge with no assignment is not active
**Preconditions:** A Super Admin account is active; a challenge has no assignment.
**Steps:**
1. As a family, view the challenges.
2. Observe the result and verify the full behavior: the unassigned challenge is not shown.
**Expected Result:** The challenge is not active — it is not shown, delivered exactly as documented.
**Priority:** High

### TC-SA-PS-01-036 — Rule: challenge actions are audit-logged
**Type:** Positive
**Covers:** 1.5 → Audit logging of parent challenges
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, create a challenge and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the action is recorded with the actor and timestamp.
**Expected Result:** The action is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High
