# 3. Career Recommendation Engine — Test Cases

User Type: **Super Administrator**
Source: *Mi Digital Academy - Education CRM Features Document*
Spec: career_recommendation_engine.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 |
|---------|--------------------|----------|
| 3.1 Recommendation Rules | Rule creation | TC-SA-CG-03-001 |
| 3.1 Recommendation Rules | Rule conditions | TC-SA-CG-03-002 |
| 3.1 Recommendation Rules | Rule actions | TC-SA-CG-03-003 |
| 3.1 Recommendation Rules | Rule priority | TC-SA-CG-03-004 |
| 3.1 Recommendation Rules | Rule enablement | TC-SA-CG-03-005 |
| 3.1 Recommendation Rules | Rule: a creation requires a condition and an action | TC-SA-CG-03-006 |
| 3.1 Recommendation Rules | Rule: a rule with no matching condition produces no recommendation | TC-SA-CG-03-007 |
| 3.1 Recommendation Rules | Rule: rule actions are audit-logged | TC-SA-CG-03-008 |
| 3.2 Strength-Based Matching | Strength mapping | TC-SA-CG-03-009 |
| 3.2 Strength-Based Matching | Match threshold | TC-SA-CG-03-010 |
| 3.2 Strength-Based Matching | Match scoring | TC-SA-CG-03-011 |
| 3.2 Strength-Based Matching | Multi-strength matching | TC-SA-CG-03-012 |
| 3.2 Strength-Based Matching | Match preview | TC-SA-CG-03-013 |
| 3.2 Strength-Based Matching | Rule: a match below the threshold is not recommended | TC-SA-CG-03-014 |
| 3.2 Strength-Based Matching | Rule: matching changes are audit-logged | TC-SA-CG-03-015 |
| 3.3 Path Recommendations | Recommendation generation | TC-SA-CG-03-016 |
| 3.3 Path Recommendations | Recommendation ranking | TC-SA-CG-03-017 |
| 3.3 Path Recommendations | Recommendation limit | TC-SA-CG-03-018 |
| 3.3 Path Recommendations | Recommendation context | TC-SA-CG-03-019 |
| 3.3 Path Recommendations | Recommendation history | TC-SA-CG-03-020 |
| 3.3 Path Recommendations | Rule: a recommendation with no match shows a fallback | TC-SA-CG-03-021 |
| 3.3 Path Recommendations | Rule: recommendation actions are audit-logged | TC-SA-CG-03-022 |
| 3.4 Resource Recommendations | Resource mapping | TC-SA-CG-03-023 |
| 3.4 Resource Recommendations | Resource relevance | TC-SA-CG-03-024 |
| 3.4 Resource Recommendations | Resource ranking | TC-SA-CG-03-025 |
| 3.4 Resource Recommendations | Resource limit | TC-SA-CG-03-026 |
| 3.4 Resource Recommendations | Resource preview | TC-SA-CG-03-027 |
| 3.4 Resource Recommendations | Rule: a resource with no mapping is not recommended | TC-SA-CG-03-028 |
| 3.4 Resource Recommendations | Rule: resource actions are audit-logged | TC-SA-CG-03-029 |
| 3.5 Recommendation Delivery | Delivery channel | TC-SA-CG-03-030 |
| 3.5 Recommendation Delivery | Delivery timing | TC-SA-CG-03-031 |
| 3.5 Recommendation Delivery | Delivery frequency | TC-SA-CG-03-032 |
| 3.5 Recommendation Delivery | Delivery tracking | TC-SA-CG-03-033 |
| 3.5 Recommendation Delivery | Delivery status | TC-SA-CG-03-034 |
| 3.5 Recommendation Delivery | Rule: a delivery to a learner with no recommendation is skipped | TC-SA-CG-03-035 |
| 3.5 Recommendation Delivery | Rule: delivery actions are audit-logged | TC-SA-CG-03-036 |

### TC-SA-CG-03-001 — Rule creation
**Type:** Positive
**Covers:** 3.1 → Rule creation: the creation of a recommendation rule
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, create a rule with a condition and an action.
2. Save the rule.
3. Observe the result and verify the full behavior: the rule is created and listed.
**Expected Result:** The creation works — the rule is listed, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-002 — Rule conditions
**Type:** Positive
**Covers:** 3.1 → Rule conditions: the conditions that trigger a recommendation
**Preconditions:** A Super Admin account is active; a rule exists.
**Steps:**
1. As a Super Admin, add a condition (aptitude threshold) and save.
2. Observe the result and verify the full behavior: the condition is recorded.
**Expected Result:** The condition is set — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-003 — Rule actions
**Type:** Positive
**Covers:** 3.1 → Rule actions: the recommendation produced by the rule
**Preconditions:** A Super Admin account is active; a rule exists.
**Steps:**
1. As a Super Admin, set the action (recommend a path) and save.
2. Observe the result and verify the full behavior: the action is recorded.
**Expected Result:** The action is set — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-004 — Rule priority
**Type:** Positive
**Covers:** 3.1 → Rule priority: the priority order of the rules
**Preconditions:** A Super Admin account is active; multiple rules exist.
**Steps:**
1. As a Super Admin, set the priority order and save.
2. Observe the result and verify the full behavior: the rules are ordered by priority.
**Expected Result:** The priority is applied — the rules are ordered, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-005 — Rule enablement
**Type:** Positive
**Covers:** 3.1 → Rule enablement: the rule toggled active or inactive
**Preconditions:** A Super Admin account is active; a rule exists.
**Steps:**
1. As a Super Admin, activate the rule.
2. Observe the result and verify the full behavior: the rule is applied.
**Expected Result:** The enablement works — the rule is applied, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-006 — Rule: a creation requires a condition and an action
**Type:** Negative
**Covers:** 3.1 → Rule: a rule creation requires at least one condition and one action
**Preconditions:** A Super Admin account is active; no action is set.
**Steps:**
1. As a Super Admin, attempt to create the rule without an action.
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-CG-03-007 — Rule: a rule with no matching condition produces no recommendation
**Type:** Positive
**Covers:** 3.1 → Rule: a rule with no matching condition produces no recommendation
**Preconditions:** A Super Admin account is active; a learner does not match the condition.
**Steps:**
1. As a Super Admin, generate recommendations for the learner.
2. Observe the result and verify the full behavior: no recommendation from the rule is produced.
**Expected Result:** No recommendation is produced — the condition is not met, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-008 — Rule: rule actions are audit-logged
**Type:** Positive
**Covers:** 3.1 → Audit logging of recommendation rules
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, create a rule 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-CG-03-009 — Strength mapping
**Type:** Positive
**Covers:** 3.2 → Strength mapping: the mapping of strengths to career paths
**Preconditions:** A Super Admin account is active; a strength and a path exist.
**Steps:**
1. As a Super Admin, map the strength to the path and save.
2. Observe the result and verify the full behavior: the mapping is recorded.
**Expected Result:** The mapping is applied — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-010 — Match threshold
**Type:** Positive
**Covers:** 3.2 → Match threshold: the threshold for a strength match
**Preconditions:** A Super Admin account is active; the matching is configured.
**Steps:**
1. As a Super Admin, set the match threshold and save.
2. Observe the result and verify the full behavior: the threshold is applied.
**Expected Result:** The threshold is set — it is applied, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-011 — Match scoring
**Type:** Positive
**Covers:** 3.2 → Match scoring: the scoring of the match strength
**Preconditions:** A Super Admin account is active; matches exist.
**Steps:**
1. As a Super Admin, review the match scoring.
2. Observe the result and verify the full behavior: the matches are ranked by strength.
**Expected Result:** The scoring is applied — the matches are ranked, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-012 — Multi-strength matching
**Type:** Positive
**Covers:** 3.2 → Multi-strength matching: the matching across multiple strengths
**Preconditions:** A Super Admin account is active; a learner has multiple strengths.
**Steps:**
1. As a Super Admin, generate the matches for the learner.
2. Observe the result and verify the full behavior: the strengths are combined in the match.
**Expected Result:** The matching works — the strengths are combined, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-013 — Match preview
**Type:** Positive
**Covers:** 3.2 → Match preview: the preview of the matches
**Preconditions:** A Super Admin account is active; the matching is configured.
**Steps:**
1. As a Super Admin, open the match preview.
2. Observe the result and verify the full behavior: the expected matches are shown.
**Expected Result:** The preview is shown — the matches are visible, delivered exactly as documented.
**Priority:** Low

### TC-SA-CG-03-014 — Rule: a match below the threshold is not recommended
**Type:** Negative
**Covers:** 3.2 → Rule: a match below the threshold is not recommended
**Preconditions:** A Super Admin account is active; a learner's strength is below the threshold.
**Steps:**
1. As a Super Admin, generate the recommendations.
2. Observe the result and verify the full behavior: the below-threshold match is not recommended.
**Expected Result:** The match is excluded — it is not recommended, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-015 — Rule: matching changes are audit-logged
**Type:** Positive
**Covers:** 3.2 → Audit logging of strength-based matching
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, set the match threshold and save.
2. Open the audit log.
3. Observe the result and verify the full behavior: the change is recorded with the actor and timestamp.
**Expected Result:** The change is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-016 — Recommendation generation
**Type:** Positive
**Covers:** 3.3 → Recommendation generation: the generation of path recommendations
**Preconditions:** A Super Admin account is active; a learner has an aptitude profile.
**Steps:**
1. As a Super Admin, generate the recommendations for the learner.
2. Observe the result and verify the full behavior: the recommendations are produced.
**Expected Result:** The generation works — the recommendations are produced, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-017 — Recommendation ranking
**Type:** Positive
**Covers:** 3.3 → Recommendation ranking: the ranking of the recommendations
**Preconditions:** A Super Admin account is active; multiple recommendations exist.
**Steps:**
1. As a Super Admin, review the ranking.
2. Observe the result and verify the full behavior: the recommendations are ordered by fit.
**Expected Result:** The ranking is applied — the recommendations are ordered, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-018 — Recommendation limit
**Type:** Positive
**Covers:** 3.3 → Recommendation limit: the number of recommendations shown
**Preconditions:** A Super Admin account is active; the limit is 3; 5 recommendations exist.
**Steps:**
1. As a Super Admin, view the recommendations.
2. Observe the result and verify the full behavior: only 3 are shown.
**Expected Result:** The limit is applied — only 3 are shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-019 — Recommendation context
**Type:** Positive
**Covers:** 3.3 → Recommendation context: the context for the recommendation
**Preconditions:** A Super Admin account is active; a recommendation exists.
**Steps:**
1. As a Super Admin, view the recommendation context.
2. Observe the result and verify the full behavior: the reason is explained.
**Expected Result:** The context is shown — the reason is explained, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-020 — Recommendation history
**Type:** Positive
**Covers:** 3.3 → Recommendation history: the history of recommendations per learner
**Preconditions:** A Super Admin account is active; a learner has past recommendations.
**Steps:**
1. As a Super Admin, open the recommendation history.
2. Observe the result and verify the full behavior: the past recommendations are listed.
**Expected Result:** The history is shown — the recommendations are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-CG-03-021 — Rule: a recommendation with no match shows a fallback
**Type:** Positive
**Covers:** 3.3 → Rule: a recommendation with no match shows a fallback message
**Preconditions:** A Super Admin account is active; a learner has no matching path.
**Steps:**
1. As a Super Admin, generate the recommendations.
2. Observe the result and verify the full behavior: a fallback message is shown.
**Expected Result:** The fallback is shown — the message is displayed, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-022 — Rule: recommendation actions are audit-logged
**Type:** Positive
**Covers:** 3.3 → Audit logging of path recommendations
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, generate the recommendations.
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-CG-03-023 — Resource mapping
**Type:** Positive
**Covers:** 3.4 → Resource mapping: the mapping of resources to career paths
**Preconditions:** A Super Admin account is active; a resource and a path exist.
**Steps:**
1. As a Super Admin, map the resource to the path and save.
2. Observe the result and verify the full behavior: the mapping is recorded.
**Expected Result:** The mapping is applied — it is recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-024 — Resource relevance
**Type:** Positive
**Covers:** 3.4 → Resource relevance: the relevance of the resource to the path
**Preconditions:** A Super Admin account is active; a resource is mapped.
**Steps:**
1. As a Super Admin, set the relevance and save.
2. Observe the result and verify the full behavior: the relevance is scored.
**Expected Result:** The relevance is set — it is scored, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-025 — Resource ranking
**Type:** Positive
**Covers:** 3.4 → Resource ranking: the ranking of the resources
**Preconditions:** A Super Admin account is active; multiple resources are mapped.
**Steps:**
1. As a Super Admin, review the resource ranking.
2. Observe the result and verify the full behavior: the resources are ordered by relevance.
**Expected Result:** The ranking is applied — the resources are ordered, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-026 — Resource limit
**Type:** Positive
**Covers:** 3.4 → Resource limit: the number of resources shown
**Preconditions:** A Super Admin account is active; the limit is 5; 8 resources exist.
**Steps:**
1. As a Super Admin, view the resource recommendations.
2. Observe the result and verify the full behavior: only 5 are shown.
**Expected Result:** The limit is applied — only 5 are shown, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-027 — Resource preview
**Type:** Positive
**Covers:** 3.4 → Resource preview: the preview of the resource recommendations
**Preconditions:** A Super Admin account is active; the resources are mapped.
**Steps:**
1. As a Super Admin, open the resource preview.
2. Observe the result and verify the full behavior: the expected recommendations are shown.
**Expected Result:** The preview is shown — the recommendations are visible, delivered exactly as documented.
**Priority:** Low

### TC-SA-CG-03-028 — Rule: a resource with no mapping is not recommended
**Type:** Negative
**Covers:** 3.4 → Rule: a resource with no mapping is not recommended
**Preconditions:** A Super Admin account is active; a resource has no mapping.
**Steps:**
1. As a Super Admin, generate the resource recommendations.
2. Observe the result and verify the full behavior: the unmapped resource is not recommended.
**Expected Result:** The resource is excluded — it is not recommended, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-029 — Rule: resource actions are audit-logged
**Type:** Positive
**Covers:** 3.4 → Audit logging of resource recommendations
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, map a resource 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-CG-03-030 — Delivery channel
**Type:** Positive
**Covers:** 3.5 → Delivery channel: the channel for the recommendation
**Preconditions:** A Super Admin account is active; the delivery is configured.
**Steps:**
1. As a Super Admin, set the channel to in-app and save.
2. Observe the result and verify the full behavior: the recommendation is delivered in-app.
**Expected Result:** The channel is applied — the recommendation is delivered in-app, delivered exactly as documented.
**Priority:** High

### TC-SA-CG-03-031 — Delivery timing
**Type:** Positive
**Covers:** 3.5 → Delivery timing: the timing of the recommendation delivery
**Preconditions:** A Super Admin account is active; the delivery is configured.
**Steps:**
1. As a Super Admin, set the timing and save.
2. Observe the result and verify the full behavior: the recommendation is sent at the timing.
**Expected Result:** The timing is applied — the recommendation is sent on time, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-032 — Delivery frequency
**Type:** Positive
**Covers:** 3.5 → Delivery frequency: the frequency of the recommendations
**Preconditions:** A Super Admin account is active; the delivery is configured.
**Steps:**
1. As a Super Admin, set the frequency to weekly and save.
2. Observe the result and verify the full behavior: the recommendations are sent weekly.
**Expected Result:** The frequency is applied — the recommendations are sent weekly, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-033 — Delivery tracking
**Type:** Positive
**Covers:** 3.5 → Delivery tracking: the tracking of the delivered recommendations
**Preconditions:** A Super Admin account is active; recommendations have been delivered.
**Steps:**
1. As a Super Admin, open the delivery tracking.
2. Observe the result and verify the full behavior: the delivered recommendations are listed.
**Expected Result:** The tracking is shown — the deliveries are listed, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-034 — Delivery status
**Type:** Positive
**Covers:** 3.5 → Delivery status: the status of the delivery
**Preconditions:** A Super Admin account is active; a delivery is in progress.
**Steps:**
1. As a Super Admin, view the delivery status.
2. Observe the result and verify the full behavior: the state is shown.
**Expected Result:** The status is shown — it reflects the state, delivered exactly as documented.
**Priority:** Low

### TC-SA-CG-03-035 — Rule: a delivery to a learner with no recommendation is skipped
**Type:** Positive
**Covers:** 3.5 → Rule: a delivery to a learner with no recommendation is skipped
**Preconditions:** A Super Admin account is active; a learner has no recommendation.
**Steps:**
1. As a Super Admin, trigger the delivery.
2. Observe the result and verify the full behavior: the delivery to the learner is skipped.
**Expected Result:** The delivery is skipped — no recommendation is sent, delivered exactly as documented.
**Priority:** Medium

### TC-SA-CG-03-036 — Rule: delivery actions are audit-logged
**Type:** Positive
**Covers:** 3.5 → Audit logging of recommendation delivery
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, trigger the delivery.
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
