# 4. Study Room Analytics — Test Cases

User Type: **Super Administrator**
Source: *Mi Digital Academy - Education CRM Features Document*
Spec: study_room_analytics.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 |
|---------|--------------------|----------|
| 4.1 Room Usage | Usage count | TC-SA-VR-04-001 |
| 4.1 Room Usage | Usage rate | TC-SA-VR-04-002 |
| 4.1 Room Usage | Per-room breakdown | TC-SA-VR-04-003 |
| 4.1 Room Usage | Usage by subject | TC-SA-VR-04-004 |
| 4.1 Room Usage | Usage trend | TC-SA-VR-04-005 |
| 4.1 Room Usage | Rule: a report is exportable in CSV | TC-SA-VR-04-006 |
| 4.1 Room Usage | Rule: report generation is audit-logged | TC-SA-VR-04-007 |
| 4.2 Session Engagement | Engagement count | TC-SA-VR-04-008 |
| 4.2 Session Engagement | Engagement rate | TC-SA-VR-04-009 |
| 4.2 Session Engagement | Per-session breakdown | TC-SA-VR-04-010 |
| 4.2 Session Engagement | Engagement duration | TC-SA-VR-04-011 |
| 4.2 Session Engagement | Engagement trend | TC-SA-VR-04-012 |
| 4.2 Session Engagement | Rule: a report is exportable in CSV | TC-SA-VR-04-013 |
| 4.2 Session Engagement | Rule: report generation is audit-logged | TC-SA-VR-04-014 |
| 4.3 Partner Effectiveness | Effectiveness score | TC-SA-VR-04-015 |
| 4.3 Partner Effectiveness | Effectiveness components | TC-SA-VR-04-016 |
| 4.3 Partner Effectiveness | Per-partner breakdown | TC-SA-VR-04-017 |
| 4.3 Partner Effectiveness | Effectiveness by goal | TC-SA-VR-04-018 |
| 4.3 Partner Effectiveness | Effectiveness trend | TC-SA-VR-04-019 |
| 4.3 Partner Effectiveness | Rule: a report is exportable in CSV | TC-SA-VR-04-020 |
| 4.3 Partner Effectiveness | Rule: report generation is audit-logged | TC-SA-VR-04-021 |
| 4.4 Analytics Export | Export format | TC-SA-VR-04-022 |
| 4.4 Analytics Export | Export scope | TC-SA-VR-04-023 |
| 4.4 Analytics Export | Export scheduling | TC-SA-VR-04-024 |
| 4.4 Analytics Export | Export history | TC-SA-VR-04-025 |
| 4.4 Analytics Export | Export log | TC-SA-VR-04-026 |
| 4.4 Analytics Export | Rule: an export with no data produces an empty file | TC-SA-VR-04-027 |
| 4.4 Analytics Export | Rule: export actions are audit-logged | TC-SA-VR-04-028 |

### TC-SA-VR-04-001 — Usage count
**Type:** Positive
**Covers:** 4.1 → Usage count: the count of the room usage
**Preconditions:** A Super Admin account is active; room sessions exist.
**Steps:**
1. As a Super Admin, open the room usage analytics.
2. Observe the result and verify the full behavior: the usage count is shown.
**Expected Result:** The count is shown — it is accurate, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-002 — Usage rate
**Type:** Positive
**Covers:** 4.1 → Usage rate: the rate of the room usage
**Preconditions:** A Super Admin account is active; rooms exist.
**Steps:**
1. As a Super Admin, view the usage rate.
2. Observe the result and verify the full behavior: the rate is shown.
**Expected Result:** The rate is shown — it is accurate, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-003 — Per-room breakdown
**Type:** Positive
**Covers:** 4.1 → Per-room breakdown: the usage per room
**Preconditions:** A Super Admin account is active; usage exists for multiple rooms.
**Steps:**
1. As a Super Admin, view the per-room breakdown.
2. Observe the result and verify the full behavior: the usage is separated per room.
**Expected Result:** The breakdown is shown — the usage is separated, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-004 — Usage by subject
**Type:** Positive
**Covers:** 4.1 → Usage by subject: the usage per subject
**Preconditions:** A Super Admin account is active; usage exists for multiple subjects.
**Steps:**
1. As a Super Admin, view the usage by subject.
2. Observe the result and verify the full behavior: the usage is separated per subject.
**Expected Result:** The breakdown is shown — the usage is separated, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-005 — Usage trend
**Type:** Positive
**Covers:** 4.1 → Usage trend: the usage over time
**Preconditions:** A Super Admin account is active; usage exists over time.
**Steps:**
1. As a Super Admin, view the usage trend.
2. Observe the result and verify the full behavior: the trend is shown.
**Expected Result:** The trend is shown — it reflects the change over time, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-006 — Rule: a report is exportable in CSV
**Type:** Positive
**Covers:** 4.1 → Rule: a report is exportable in CSV
**Preconditions:** A Super Admin account is active; the report has data.
**Steps:**
1. As a Super Admin, export the report in CSV.
2. Open the exported file.
3. Observe the result and verify the full behavior: the data is present and correct.
**Expected Result:** The export works — the CSV contains the data, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-007 — Rule: report generation is audit-logged
**Type:** Positive
**Covers:** 4.1 → Audit logging of room usage
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, generate the report.
2. Open the audit log.
3. Observe the result and verify the full behavior: the generation is recorded with the actor and timestamp.
**Expected Result:** The generation is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-008 — Engagement count
**Type:** Positive
**Covers:** 4.2 → Engagement count: the count of the engaged learners
**Preconditions:** A Super Admin account is active; sessions have engaged learners.
**Steps:**
1. As a Super Admin, open the session engagement analytics.
2. Observe the result and verify the full behavior: the engagement count is shown.
**Expected Result:** The count is shown — it is accurate, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-009 — Engagement rate
**Type:** Positive
**Covers:** 4.2 → Engagement rate: the rate of the engagement
**Preconditions:** A Super Admin account is active; sessions have learners.
**Steps:**
1. As a Super Admin, view the engagement rate.
2. Observe the result and verify the full behavior: the rate is shown.
**Expected Result:** The rate is shown — it is accurate, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-010 — Per-session breakdown
**Type:** Positive
**Covers:** 4.2 → Per-session breakdown: the engagement per session
**Preconditions:** A Super Admin account is active; engagement exists for multiple sessions.
**Steps:**
1. As a Super Admin, view the per-session breakdown.
2. Observe the result and verify the full behavior: the engagement is separated per session.
**Expected Result:** The breakdown is shown — the engagement is separated, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-011 — Engagement duration
**Type:** Positive
**Covers:** 4.2 → Engagement duration: the duration of the engagement
**Preconditions:** A Super Admin account is active; sessions have engaged learners.
**Steps:**
1. As a Super Admin, view the engagement duration.
2. Observe the result and verify the full behavior: the duration is shown.
**Expected Result:** The duration is shown — it is accurate, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-012 — Engagement trend
**Type:** Positive
**Covers:** 4.2 → Engagement trend: the engagement over time
**Preconditions:** A Super Admin account is active; engagement exists over time.
**Steps:**
1. As a Super Admin, view the engagement trend.
2. Observe the result and verify the full behavior: the trend is shown.
**Expected Result:** The trend is shown — it reflects the change over time, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-013 — Rule: a report is exportable in CSV
**Type:** Positive
**Covers:** 4.2 → Rule: a report is exportable in CSV
**Preconditions:** A Super Admin account is active; the report has data.
**Steps:**
1. As a Super Admin, export the report in CSV.
2. Open the exported file.
3. Observe the result and verify the full behavior: the data is present and correct.
**Expected Result:** The export works — the CSV contains the data, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-014 — Rule: report generation is audit-logged
**Type:** Positive
**Covers:** 4.2 → Audit logging of session engagement
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, generate the report.
2. Open the audit log.
3. Observe the result and verify the full behavior: the generation is recorded with the actor and timestamp.
**Expected Result:** The generation is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-015 — Effectiveness score
**Type:** Positive
**Covers:** 4.3 → Effectiveness score: the score of the partner effectiveness
**Preconditions:** A Super Admin account is active; partner metrics exist.
**Steps:**
1. As a Super Admin, open the partner effectiveness analytics.
2. Observe the result and verify the full behavior: the effectiveness score is shown.
**Expected Result:** The score is shown — it is accurate, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-016 — Effectiveness components
**Type:** Positive
**Covers:** 4.3 → Effectiveness components: the components of the score
**Preconditions:** A Super Admin account is active; an effectiveness score is computed.
**Steps:**
1. As a Super Admin, view the effectiveness components.
2. Observe the result and verify the full behavior: the components are shown.
**Expected Result:** The components are shown — they are listed, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-017 — Per-partner breakdown
**Type:** Positive
**Covers:** 4.3 → Per-partner breakdown: the effectiveness per partner
**Preconditions:** A Super Admin account is active; effectiveness exists for multiple partners.
**Steps:**
1. As a Super Admin, view the per-partner breakdown.
2. Observe the result and verify the full behavior: the effectiveness is separated per partner.
**Expected Result:** The breakdown is shown — the effectiveness is separated, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-018 — Effectiveness by goal
**Type:** Positive
**Covers:** 4.3 → Effectiveness by goal: the effectiveness per goal
**Preconditions:** A Super Admin account is active; effectiveness exists for multiple goals.
**Steps:**
1. As a Super Admin, view the effectiveness by goal.
2. Observe the result and verify the full behavior: the effectiveness is separated per goal.
**Expected Result:** The breakdown is shown — the effectiveness is separated, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-019 — Effectiveness trend
**Type:** Positive
**Covers:** 4.3 → Effectiveness trend: the effectiveness over time
**Preconditions:** A Super Admin account is active; effectiveness exists over time.
**Steps:**
1. As a Super Admin, view the effectiveness trend.
2. Observe the result and verify the full behavior: the trend is shown.
**Expected Result:** The trend is shown — it reflects the change over time, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-020 — Rule: a report is exportable in CSV
**Type:** Positive
**Covers:** 4.3 → Rule: a report is exportable in CSV
**Preconditions:** A Super Admin account is active; the report has data.
**Steps:**
1. As a Super Admin, export the report in CSV.
2. Open the exported file.
3. Observe the result and verify the full behavior: the data is present and correct.
**Expected Result:** The export works — the CSV contains the data, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-021 — Rule: report generation is audit-logged
**Type:** Positive
**Covers:** 4.3 → Audit logging of partner effectiveness
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, generate the report.
2. Open the audit log.
3. Observe the result and verify the full behavior: the generation is recorded with the actor and timestamp.
**Expected Result:** The generation is audit-logged — the actor and timestamp are recorded, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-022 — Export format
**Type:** Positive
**Covers:** 4.4 → Export format: the format of the export
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, set the export format to CSV and save.
2. Observe the result and verify the full behavior: the format is applied.
**Expected Result:** The format is set — it is applied, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-023 — Export scope
**Type:** Positive
**Covers:** 4.4 → Export scope: the scope of the export
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, set the export scope and save.
2. Observe the result and verify the full behavior: the scope is applied.
**Expected Result:** The scope is set — it is applied, delivered exactly as documented.
**Priority:** High

### TC-SA-VR-04-024 — Export scheduling
**Type:** Positive
**Covers:** 4.4 → Export scheduling: the scheduling of the export
**Preconditions:** A Super Admin account is active.
**Steps:**
1. As a Super Admin, schedule the export and save.
2. Observe the result and verify the full behavior: the export repeats.
**Expected Result:** The scheduling works — the export repeats, delivered exactly as documented.
**Priority:** Medium

### TC-SA-VR-04-025 — Export history
**Type:** Positive
**Covers:** 4.4 → Export history: the history of the exports
**Preconditions:** A Super Admin account is active; exports have a history.
**Steps:**
1. As a Super Admin, open the export history.
2. Observe the result and verify the full behavior: the past exports are listed.
**Expected Result:** The history is shown — the exports are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-026 — Export log
**Type:** Positive
**Covers:** 4.4 → Export log: the log of the exports
**Preconditions:** A Super Admin account is active; exports exist.
**Steps:**
1. As a Super Admin, open the export log.
2. Observe the result and verify the full behavior: the exports are listed.
**Expected Result:** The log is shown — the exports are listed, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-027 — Rule: an export with no data produces an empty file
**Type:** Positive
**Covers:** 4.4 → Rule: an export with no data produces an empty file
**Preconditions:** A Super Admin account is active; the export has no data.
**Steps:**
1. As a Super Admin, run the export.
2. Open the exported file.
3. Observe the result and verify the full behavior: the file is empty.
**Expected Result:** The file is empty — it is produced, delivered exactly as documented.
**Priority:** Low

### TC-SA-VR-04-028 — Rule: export actions are audit-logged
**Type:** Positive
**Covers:** 4.4 → Audit logging of analytics export
**Preconditions:** A Super Admin account is active; the audit log is accessible.
**Steps:**
1. As a Super Admin, run the export.
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
