# 3. Learning Patterns & Insights — Test Cases

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

---

## Test Execution Policy
- Zero tolerance: any deviation from documented behavior = FAILED = bug
- Every bug is immediately logged/reported (Bug ID, feature, sub-feature, expected vs actual, severity) and fixed 100% before the group passes
- Feature group passes only at 100% test pass rate

## Coverage Matrix
| Feature | Sub-feature / Rule | Test IDs |
|---------|--------------------|----------|
| 3.1 Learning Pattern Insights | Peak performance times identified | TC-ST-08-03-001 |
| 3.1 Learning Pattern Insights | Common error patterns identified | TC-ST-08-03-002 |
| 3.1 Learning Pattern Insights | Study habit insights (consistency, session length) | TC-ST-08-03-003 |
| 3.1 Learning Pattern Insights | Insights per subject | TC-ST-08-03-004 |
| 3.1 Learning Pattern Insights | Insights update as data accumulates | TC-ST-08-03-005 |
| 3.1 Learning Pattern Insights | Insights available on web and mobile | TC-ST-08-03-006 |
| 3.1 Learning Pattern Insights | Insight event logging (computed) | TC-ST-08-03-007 |
| 3.1 Learning Pattern Insights | Audit logging of the learning pattern insights | TC-ST-08-03-008 |
| 3.1 Learning Pattern Insights | Rule: Peak performance times are derived from assessment performance by time of day. | TC-ST-08-03-001 |
| 3.1 Learning Pattern Insights | Rule: Common error patterns are derived from repeated wrong answers. | TC-ST-08-03-002 |
| 3.1 Learning Pattern Insights | Rule: Study habit insights reflect consistency and session length. | TC-ST-08-03-003 |
| 3.1 Learning Pattern Insights | Rule: Insights update as data accumulates. | TC-ST-08-03-004 |
| 3.1 Learning Pattern Insights | Rule: Insight events (computed) are logged with the timestamp. | TC-ST-08-03-005 |
| 3.1 Learning Pattern Insights | Rule: The learning pattern insights is audit-logged with the account and the timestamp. | TC-ST-08-03-006 |
| 3.2 Study Consistency and Streaks | Study streak (consecutive days) | TC-ST-08-03-009 |
| 3.2 Study Consistency and Streaks | Consistency over a rolling period | TC-ST-08-03-010 |
| 3.2 Study Consistency and Streaks | Consistency milestones | TC-ST-08-03-011 |
| 3.2 Study Consistency and Streaks | Streak and consistency on the dashboard | TC-ST-08-03-012 |
| 3.2 Study Consistency and Streaks | Consistency feeds gamification | TC-ST-08-03-013 |
| 3.2 Study Consistency and Streaks | Consistency available on web and mobile | TC-ST-08-03-014 |
| 3.2 Study Consistency and Streaks | Consistency event logging (streak updated) | TC-ST-08-03-015 |
| 3.2 Study Consistency and Streaks | Audit logging of the study consistency and streaks | TC-ST-08-03-016 |
| 3.2 Study Consistency and Streaks | Rule: A streak counts consecutive days with at least one study action. | TC-ST-08-03-009 |
| 3.2 Study Consistency and Streaks | Rule: Consistency is computed over a rolling period. | TC-ST-08-03-010 |
| 3.2 Study Consistency and Streaks | Rule: Milestones are celebrated at defined thresholds. | TC-ST-08-03-011 |
| 3.2 Study Consistency and Streaks | Rule: Consistency feeds the Student's gamification. | TC-ST-08-03-012 |
| 3.2 Study Consistency and Streaks | Rule: Consistency events (streak updated) are logged with the timestamp. | TC-ST-08-03-013 |
| 3.2 Study Consistency and Streaks | Rule: The study consistency and streaks is audit-logged with the account and the timestamp. | TC-ST-08-03-014 |
| 3.3 Personalized Recommendations | "What to study next" recommendation | TC-ST-08-03-017 |
| 3.3 Personalized Recommendations | Recommended resources (videos, flashcards, guides) | TC-ST-08-03-018 |
| 3.3 Personalized Recommendations | Improvement suggestions for weak areas | TC-ST-08-03-019 |
| 3.3 Personalized Recommendations | Recommendations based on performance and patterns | TC-ST-08-03-020 |
| 3.3 Personalized Recommendations | Recommendations update as the Student progresses | TC-ST-08-03-021 |
| 3.3 Personalized Recommendations | Recommendations available on web and mobile | TC-ST-08-03-022 |
| 3.3 Personalized Recommendations | Recommendation event logging (generated, acted on) | TC-ST-08-03-023 |
| 3.3 Personalized Recommendations | Audit logging of the personalized recommendations | TC-ST-08-03-024 |
| 3.3 Personalized Recommendations | Rule: Recommendations are derived from the Student's performance and patterns. | TC-ST-08-03-017 |
| 3.3 Personalized Recommendations | Rule: A recommendation links to a specific resource or action. | TC-ST-08-03-018 |
| 3.3 Personalized Recommendations | Rule: Recommendations update as the Student progresses. | TC-ST-08-03-019 |
| 3.3 Personalized Recommendations | Rule: Acting on a recommendation is recorded. | TC-ST-08-03-020 |
| 3.3 Personalized Recommendations | Rule: Recommendation events (generated, acted on) are logged with the timestamp. | TC-ST-08-03-021 |
| 3.3 Personalized Recommendations | Rule: The personalized recommendations is audit-logged with the account and the timestamp. | TC-ST-08-03-022 |

## 3.1 Learning Pattern Insights

### TC-ST-08-03-001 — Peak performance times identified
**Type:** Positive
**Covers:** 3.1 → Peak performance times identified; Rule: Peak performance times are derived from assessment performance by time of day.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Peak performance times identified.
2. Observe the result and verify the full behavior: Peak performance times identified.
**Expected Result:** Peak performance times identified — delivered exactly as documented.
**Priority:** Critical

### TC-ST-08-03-002 — Common error patterns identified
**Type:** Positive
**Covers:** 3.1 → Common error patterns identified; Rule: Common error patterns are derived from repeated wrong answers.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Common error patterns identified.
2. Observe the result and verify the full behavior: Common error patterns identified.
**Expected Result:** Common error patterns identified — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-003 — Study habit insights (consistency, session length)
**Type:** Positive
**Covers:** 3.1 → Study habit insights (consistency, session length); Rule: Study habit insights reflect consistency and session length.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Study habit insights (consistency.
2. Observe the result and verify the full behavior: Study habit insights (consistency, session length).
**Expected Result:** Study habit insights (consistency, session length) — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-004 — Insights per subject
**Type:** Positive
**Covers:** 3.1 → Insights per subject; Rule: Insights update as data accumulates.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Insights per subject.
2. Observe the result and verify the full behavior: Insights per subject.
**Expected Result:** Insights per subject — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-005 — Insights update as data accumulates
**Type:** Positive
**Covers:** 3.1 → Insights update as data accumulates; Rule: Insight events (computed) are logged with the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Insights update as data accumulates.
2. Observe the result and verify the full behavior: Insights update as data accumulates.
**Expected Result:** Insights update as data accumulates — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-006 — Insights available on web and mobile
**Type:** Positive
**Covers:** 3.1 → Insights available on web and mobile; Rule: The learning pattern insights is audit-logged with the account and the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Insights available on web and mobile.
2. Observe the result and verify the full behavior: Insights available on web and mobile.
**Expected Result:** Insights available on web and mobile — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-007 — Insight event logging (computed)
**Type:** Positive
**Covers:** 3.1 → Insight event logging (computed)
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Insight event logging (computed).
2. Observe the result and verify the full behavior: Insight event logging (computed).
**Expected Result:** Insight event logging (computed) — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-008 — Audit logging of the learning pattern insights
**Type:** Positive
**Covers:** 3.1 → Audit logging of the learning pattern insights
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, perform the action associated with: Audit logging of the learning pattern insights.
2. Open the relevant activity / audit log and verify the event is recorded with the account, the action, and the timestamp.
**Expected Result:** The action is audit-logged — the account, the action, and the timestamp are recorded.
**Priority:** Critical

## 3.2 Study Consistency and Streaks

### TC-ST-08-03-009 — Study streak (consecutive days)
**Type:** Positive
**Covers:** 3.2 → Study streak (consecutive days); Rule: A streak counts consecutive days with at least one study action.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Study streak (consecutive days).
2. Observe the result and verify the full behavior: Study streak (consecutive days).
**Expected Result:** Study streak (consecutive days) — delivered exactly as documented.
**Priority:** Critical

### TC-ST-08-03-010 — Consistency over a rolling period
**Type:** Positive
**Covers:** 3.2 → Consistency over a rolling period; Rule: Consistency is computed over a rolling period.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Consistency over a rolling period.
2. Observe the result and verify the full behavior: Consistency over a rolling period.
**Expected Result:** Consistency over a rolling period — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-011 — Consistency milestones
**Type:** Positive
**Covers:** 3.2 → Consistency milestones; Rule: Milestones are celebrated at defined thresholds.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Consistency milestones.
2. Observe the result and verify the full behavior: Consistency milestones.
**Expected Result:** Consistency milestones — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-012 — Streak and consistency on the dashboard
**Type:** Positive
**Covers:** 3.2 → Streak and consistency on the dashboard; Rule: Consistency feeds the Student's gamification.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Streak and consistency on the dashboard.
2. Observe the result and verify the full behavior: Streak and consistency on the dashboard.
**Expected Result:** Streak and consistency on the dashboard — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-013 — Consistency feeds gamification
**Type:** Positive
**Covers:** 3.2 → Consistency feeds gamification; Rule: Consistency events (streak updated) are logged with the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Consistency feeds gamification.
2. Observe the result and verify the full behavior: Consistency feeds gamification.
**Expected Result:** Consistency feeds gamification — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-014 — Consistency available on web and mobile
**Type:** Positive
**Covers:** 3.2 → Consistency available on web and mobile; Rule: The study consistency and streaks is audit-logged with the account and the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Consistency available on web and mobile.
2. Observe the result and verify the full behavior: Consistency available on web and mobile.
**Expected Result:** Consistency available on web and mobile — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-015 — Consistency event logging (streak updated)
**Type:** Positive
**Covers:** 3.2 → Consistency event logging (streak updated)
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Consistency event logging (streak updated).
2. Observe the result and verify the full behavior: Consistency event logging (streak updated).
**Expected Result:** Consistency event logging (streak updated) — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-016 — Audit logging of the study consistency and streaks
**Type:** Positive
**Covers:** 3.2 → Audit logging of the study consistency and streaks
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, perform the action associated with: Audit logging of the study consistency and streaks.
2. Open the relevant activity / audit log and verify the event is recorded with the account, the action, and the timestamp.
**Expected Result:** The action is audit-logged — the account, the action, and the timestamp are recorded.
**Priority:** Critical

## 3.3 Personalized Recommendations

### TC-ST-08-03-017 — "What to study next" recommendation
**Type:** Positive
**Covers:** 3.3 → "What to study next" recommendation; Rule: Recommendations are derived from the Student's performance and patterns.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: "What to study next" recommendation.
2. Observe the result and verify the full behavior: "What to study next" recommendation.
**Expected Result:** "What to study next" recommendation — delivered exactly as documented.
**Priority:** Critical

### TC-ST-08-03-018 — Recommended resources (videos, flashcards, guides)
**Type:** Positive
**Covers:** 3.3 → Recommended resources (videos, flashcards, guides); Rule: A recommendation links to a specific resource or action.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Recommended resources (videos.
2. Observe the result and verify the full behavior: Recommended resources (videos, flashcards, guides).
**Expected Result:** Recommended resources (videos, flashcards, guides) — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-019 — Improvement suggestions for weak areas
**Type:** Edge
**Covers:** 3.3 → Improvement suggestions for weak areas; Rule: Recommendations update as the Student progresses.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Improvement suggestions for weak areas.
2. Observe the result and verify the full behavior: Improvement suggestions for weak areas.
**Expected Result:** Improvement suggestions for weak areas — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-020 — Recommendations based on performance and patterns
**Type:** Positive
**Covers:** 3.3 → Recommendations based on performance and patterns; Rule: Acting on a recommendation is recorded.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Recommendations based on performance and patterns.
2. Observe the result and verify the full behavior: Recommendations based on performance and patterns.
**Expected Result:** Recommendations based on performance and patterns — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-021 — Recommendations update as the Student progresses
**Type:** Positive
**Covers:** 3.3 → Recommendations update as the Student progresses; Rule: Recommendation events (generated, acted on) are logged with the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Recommendations update as the Student progresses.
2. Observe the result and verify the full behavior: Recommendations update as the Student progresses.
**Expected Result:** Recommendations update as the Student progresses — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-022 — Recommendations available on web and mobile
**Type:** Positive
**Covers:** 3.3 → Recommendations available on web and mobile; Rule: The personalized recommendations is audit-logged with the account and the timestamp.
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Recommendations available on web and mobile.
2. Observe the result and verify the full behavior: Recommendations available on web and mobile.
**Expected Result:** Recommendations available on web and mobile — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-023 — Recommendation event logging (generated, acted on)
**Type:** Positive
**Covers:** 3.3 → Recommendation event logging (generated, acted on)
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, set up the precondition and perform: Recommendation event logging (generated.
2. Observe the result and verify the full behavior: Recommendation event logging (generated, acted on).
**Expected Result:** Recommendation event logging (generated, acted on) — delivered exactly as documented.
**Priority:** High

### TC-ST-08-03-024 — Audit logging of the personalized recommendations
**Type:** Positive
**Covers:** 3.3 → Audit logging of the personalized recommendations
**Preconditions:** A Student account is active and the Student is in the state required for this behavior.
**Steps:**
1. As a Student, perform the action associated with: Audit logging of the personalized recommendations.
2. Open the relevant activity / audit log and verify the event is recorded with the account, the action, and the timestamp.
**Expected Result:** The action is audit-logged — the account, the action, and the timestamp are recorded.
**Priority:** Critical
