# 2. Disaster Recovery — Test Cases

User Type: **Super Administrator**
Source: *Mi Digital Academy - Education CRM Features Document*
Spec: disaster_recovery.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 |
|---------|--------------------|----------|
| 2.1 Disaster Recovery Capabilities | Capability: the capability (the capability, the scope, the plan, the date) | TC-SA-23-02-001 |
| 2.1 Disaster Recovery Capabilities | Scope: the scope (the scope of the recovery, the area, the date) | TC-SA-23-02-002 |
| 2.1 Disaster Recovery Capabilities | Plan: the plan (the plan of the recovery, the steps, the date) | TC-SA-23-02-003 |
| 2.1 Disaster Recovery Capabilities | Capability status: the status (the ready, the not-ready) | TC-SA-23-02-004 |
| 2.1 Disaster Recovery Capabilities | Capability count: the count (the count of the capabilities) | TC-SA-23-02-005 |
| 2.1 Disaster Recovery Capabilities | Capability view: the view (the capabilities, the scopes, the plans, the dates) | TC-SA-23-02-006 |
| 2.1 Disaster Recovery Capabilities | Capability export: the export (the capabilities, the format, the scope) | TC-SA-23-02-007 |
| 2.1 Disaster Recovery Capabilities | Audit logging of the disaster recovery capability configuration | TC-SA-23-02-008 |
| 2.1 Disaster Recovery Capabilities | Rule: the capability is the readiness (the capability, the scope, the plan, the date); the capability is the preparedness | TC-SA-23-02-001 |
| 2.1 Disaster Recovery Capabilities | Rule: the scope is the boundary (the scope of the recovery, the area, the date); the scope is the limit | TC-SA-23-02-002 |
| 2.1 Disaster Recovery Capabilities | Rule: the plan is the procedure (the plan of the recovery, the steps, the date); the plan is the playbook | TC-SA-23-02-003 |
| 2.1 Disaster Recovery Capabilities | Rule: the capability status is the state (the ready, the not-ready); the status is the control | TC-SA-23-02-004 |
| 2.1 Disaster Recovery Capabilities | Rule: the recovery is possible (the capabilities, the scopes, the plans, the dates); the readiness is managed | TC-SA-23-02-006 |
| 2.1 Disaster Recovery Capabilities | Rule: disaster recovery capability configuration is audit-logged with the capability, scope, and timestamp | TC-SA-23-02-008 |
| 2.2 Restore from Backup | Restore: the restore (the restore, the backup, the scope, the date) | TC-SA-23-02-009 |
| 2.2 Restore from Backup | Backup: the backup (the backup, the scope, the date) | TC-SA-23-02-010 |
| 2.2 Restore from Backup | Scope: the scope (the scope of the restore, the data, the date) | TC-SA-23-02-011 |
| 2.2 Restore from Backup | Restore status: the status (the completed, the in-progress, the failed) | TC-SA-23-02-012 |
| 2.2 Restore from Backup | Restore count: the count (the count of the restores) | TC-SA-23-02-013 |
| 2.2 Restore from Backup | Restore duration: the duration (the duration of the restore, the time) | TC-SA-23-02-014 |
| 2.2 Restore from Backup | Restore view: the view (the restores, the backups, the scopes, the dates) | TC-SA-23-02-015 |
| 2.2 Restore from Backup | Audit logging of the restore from backup | TC-SA-23-02-016 |
| 2.2 Restore from Backup | Rule: the restore is the recovery (the restore, the backup, the scope, the date); the restore is the return | TC-SA-23-02-009 |
| 2.2 Restore from Backup | Rule: the backup is the copy (the backup, the scope, the date); the backup is the safety | TC-SA-23-02-010 |
| 2.2 Restore from Backup | Rule: the scope is the boundary (the scope of the restore, the data, the date); the scope is the limit | TC-SA-23-02-011 |
| 2.2 Restore from Backup | Rule: the restore status is the state (the completed, the in-progress, the failed); the status is the control | TC-SA-23-02-012 |
| 2.2 Restore from Backup | Rule: the system is restored (the restores, the backups, the scopes, the dates); the recovery is managed | TC-SA-23-02-015 |
| 2.2 Restore from Backup | Rule: restore from backup is audit-logged with the restore, backup, and timestamp | TC-SA-23-02-016 |
| 2.3 Recovery Point and Recovery Time Tracking | Recovery point: the point (the point, the backup, the date) | TC-SA-23-02-017 |
| 2.3 Recovery Point and Recovery Time Tracking | Backup: the backup (the backup, the scope, the date) | TC-SA-23-02-018 |
| 2.3 Recovery Point and Recovery Time Tracking | Recovery time: the time (the time, the restore, the date) | TC-SA-23-02-019 |
| 2.3 Recovery Point and Recovery Time Tracking | Restore: the restore (the restore, the backup, the date) | TC-SA-23-02-020 |
| 2.3 Recovery Point and Recovery Time Tracking | Recovery point count: the count (the count of the recovery points) | TC-SA-23-02-021 |
| 2.3 Recovery Point and Recovery Time Tracking | Recovery time average: the average (the average of the recovery times, the time) | TC-SA-23-02-022 |
| 2.3 Recovery Point and Recovery Time Tracking | Recovery view: the view (the points, the backups, the times, the dates) | TC-SA-23-02-023 |
| 2.3 Recovery Point and Recovery Time Tracking | Audit logging of the recovery point and time tracking | TC-SA-23-02-024 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: the recovery point is the moment (the point, the backup, the date); the point is the position | TC-SA-23-02-017 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: the backup is the copy (the backup, the scope, the date); the backup is the safety | TC-SA-23-02-018 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: the recovery time is the duration (the time, the restore, the date); the time is the length | TC-SA-23-02-019 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: the recovery time average is the norm (the average of the recovery times, the time); the average is the baseline | TC-SA-23-02-022 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: the recovery is measured (the points, the backups, the times, the dates); the tracking is managed | TC-SA-23-02-023 |
| 2.3 Recovery Point and Recovery Time Tracking | Rule: recovery point and time tracking is audit-logged with the point, time, and timestamp | TC-SA-23-02-024 |

## 2.1 Disaster Recovery Capabilities

### TC-SA-23-02-001 — Capability: the capability (the capability, the scope, the plan, the date); the capability is the preparedness
**Type:** Positive
**Covers:** 2.1 → Capability: the capability (the capability, the scope, the plan, the date); Rule: the capability is the readiness (the capability, the scope, the plan, the date); the capability is the preparedness
**Preconditions:** Super Admin is logged in.
**Steps:**
1. Open Backup & Data Export → Disaster Recovery → Disaster Recovery Capabilities.
2. Provide the capability: the capability (the capability, the scope, the plan, the date) — verify the capability is the readiness.
3. Verify the capability shows the scope, the plan, and the date.
4. Verify the capability is executable (a recovery can actually be performed using it).
**Expected Result:** The capability is provided — the capability, the scope, the plan, and the date are the preparedness.
**Priority:** Critical

### TC-SA-23-02-002 — Scope: the scope (the scope of the recovery, the area, the date); the scope is the limit
**Type:** Positive
**Covers:** 2.1 → Scope: the scope (the scope of the recovery, the area, the date); Rule: the scope is the boundary (the scope of the recovery, the area, the date); the scope is the limit
**Preconditions:** Multiple recovery areas exist.
**Steps:**
1. Set the scope: the scope (the scope of the recovery, the area, the date) — verify the scope is the boundary.
2. Verify the scope shows the area and the date.
3. Verify a recovery covers exactly the scoped area (no area is recovered outside the scope).
**Expected Result:** The scope is set — the scope of the recovery, the area, and the date are the limit.
**Priority:** High

### TC-SA-23-02-003 — Plan: the plan (the plan of the recovery, the steps, the date); the plan is the playbook
**Type:** Positive
**Covers:** 2.1 → Plan: the plan (the plan of the recovery, the steps, the date); Rule: the plan is the procedure (the plan of the recovery, the steps, the date); the plan is the playbook
**Preconditions:** Super Admin is logged in.
**Steps:**
1. Create the plan: the plan (the plan of the recovery, the steps, the date) — verify the plan is the procedure.
2. Verify the plan shows the steps and the date.
3. Verify the steps are ordered and complete (a recovery can be executed step-by-step from the plan alone).
**Expected Result:** The plan is created — the plan of the recovery, the steps, and the date are the playbook.
**Priority:** High

### TC-SA-23-02-004 — Capability status: the status (the ready, the not-ready); the status is the control
**Type:** Edge
**Covers:** 2.1 → Capability status: the status (the ready, the not-ready); Rule: the capability status is the state (the ready, the not-ready); the status is the control
**Preconditions:** A ready capability and a not-ready capability exist (e.g., a capability whose backup dependency is missing); a recovery attempt against the not-ready capability is prepared.
**Steps:**
1. View the capability status: the status (the ready, the not-ready) — verify the capability status is the state.
2. Verify the ready capability shows ready and the broken one shows not-ready.
3. Attempt a recovery using the not-ready capability — verify the system blocks it with a clear not-ready message (a recovery never starts from a not-ready capability).
**Expected Result:** The capability status is shown — the ready and the not-ready are the control; not-ready capabilities can never start a recovery.
**Priority:** High

### TC-SA-23-02-005 — Capability count: the count (the count of the capabilities); the count is the measure
**Type:** Positive
**Covers:** 2.1 → Capability count: the count (the count of the capabilities)
**Preconditions:** Multiple capabilities exist.
**Steps:**
1. View the capability count: the count (the count of the capabilities) — verify the capability count is the measure.
2. Verify the count matches the actual number of capabilities.
3. Add a capability — verify the count increments.
**Expected Result:** The capability count is shown — the count of the capabilities is the measure.
**Priority:** High

### TC-SA-23-02-006 — Capability view: the view (the capabilities, the scopes, the plans, the dates); the readiness is managed
**Type:** Positive
**Covers:** 2.1 → Capability view: the view (the capabilities, the scopes, the plans, the dates); Rule: the recovery is possible (the capabilities, the scopes, the plans, the dates); the readiness is managed
**Preconditions:** Multiple capabilities exist.
**Steps:**
1. View the capabilities: the view (the capabilities, the scopes, the plans, the dates) — verify the recovery is possible.
2. Verify each capability shows the scope, the plan, and the date.
3. Verify the readiness is managed (view, configure, verify, test).
**Expected Result:** The capabilities are viewed — the capabilities, the scopes, the plans, and the dates are visible; the readiness is managed.
**Priority:** High

### TC-SA-23-02-007 — Capability export: the export (the capabilities, the format, the scope); the export is the record
**Type:** Edge
**Covers:** 2.1 → Capability export: the export (the capabilities, the format, the scope)
**Preconditions:** Capabilities exist for multiple scopes; a scope with no capabilities (zero-row export edge) is also prepared.
**Steps:**
1. Export the capabilities: the export (the capabilities, the format, the scope) — verify the export is the record.
2. Verify the export contains all capabilities for the selected scope in the selected format.
3. Export the empty scope — verify the export completes (empty file or clear "no data" message, no error/corrupt file).
**Expected Result:** The capabilities are exported — the capabilities, the format, and the scope are the record; empty-scope exports never produce corrupt files or errors.
**Priority:** High

### TC-SA-23-02-008 — Disaster recovery capability configuration is audit-logged with the capability, scope, and timestamp
**Type:** Positive
**Covers:** 2.1 → Audit logging of the disaster recovery capability configuration; Rule: disaster recovery capability configuration is audit-logged with the capability, scope, and timestamp
**Preconditions:** Super Admin has configured a disaster recovery capability.
**Steps:**
1. Open the audit trail and filter by "disaster recovery capability".
2. Verify entries show the capability, the scope, and the timestamp.
**Expected Result:** The disaster recovery capability configuration is audit-logged with the capability, scope, and timestamp.
**Priority:** Critical

## 2.2 Restore from Backup

### TC-SA-23-02-009 — Restore: the restore (the restore, the backup, the scope, the date); the restore is the return
**Type:** Positive
**Covers:** 2.2 → Restore: the restore (the restore, the backup, the scope, the date); Rule: the restore is the recovery (the restore, the backup, the scope, the date); the restore is the return
**Preconditions:** A completed, valid backup exists.
**Steps:**
1. Open Backup & Data Export → Disaster Recovery → Restore from Backup.
2. Restore from the backup: the restore (the restore, the backup, the scope, the date) — verify the restore is the recovery.
3. Verify the restore shows the backup, the scope, and the date.
4. Verify the restored data matches the backup exactly (full, consistent restore).
**Expected Result:** The restore is performed — the restore, the backup, the scope, and the date are the return; the system is restored.
**Priority:** Critical

### TC-SA-23-02-010 — Backup: the backup (the backup, the scope, the date); the backup is the safety
**Type:** Positive
**Covers:** 2.2 → Backup: the backup (the backup, the scope, the date); Rule: the backup is the copy (the backup, the scope, the date); the backup is the safety
**Preconditions:** Multiple completed backups exist.
**Steps:**
1. Select the backup: the backup (the backup, the scope, the date) — verify the backup is the copy.
2. Verify the backup shows the scope and the date.
3. Verify only completed, valid backups are selectable for restore.
**Expected Result:** The backup is selected — the backup, the scope, and the date are the safety.
**Priority:** High

### TC-SA-23-02-011 — Scope: the scope (the scope of the restore, the data, the date); the scope is the limit
**Type:** Positive
**Covers:** 2.2 → Scope: the scope (the scope of the restore, the data, the date); Rule: the scope is the boundary (the scope of the restore, the data, the date); the scope is the limit
**Preconditions:** A backup with multiple data areas exists.
**Steps:**
1. Set the scope: the scope (the scope of the restore, the data, the date) — verify the scope is the boundary.
2. Verify the scope shows the data and the date.
3. Restore with a partial scope — verify only the scoped data is restored (out-of-scope data is untouched).
**Expected Result:** The scope is set — the scope of the restore, the data, and the date are the limit; only scoped data is restored.
**Priority:** High

### TC-SA-23-02-012 — Restore status: the status (the completed, the in-progress, the failed); the status is the control
**Type:** Edge
**Covers:** 2.2 → Restore status: the status (the completed, the in-progress, the failed); Rule: the restore status is the state (the completed, the in-progress, the failed); the status is the control
**Preconditions:** A corrupted/incomplete backup (failed-restore edge) is prepared alongside a valid backup.
**Steps:**
1. View the restore status: the status (the completed, the in-progress, the failed) — verify the restore status is the state.
2. Start a restore — verify it shows in-progress, then completed on success.
3. Start a restore from the corrupted backup — verify the status becomes failed with the reason (never a silent partial restore reported as completed); the system is left in a known, consistent state.
**Expected Result:** The restore status is shown — the completed, the in-progress, and the failed are the control; failed restores are always surfaced, never masked as partial successes.
**Priority:** High

### TC-SA-23-02-013 — Restore count: the count (the count of the restores); the count is the measure
**Type:** Positive
**Covers:** 2.2 → Restore count: the count (the count of the restores)
**Preconditions:** Multiple restores have been performed.
**Steps:**
1. View the restore count: the count (the count of the restores) — verify the restore count is the measure.
2. Verify the count matches the actual number of restores.
3. Complete a new restore — verify the count increments.
**Expected Result:** The restore count is shown — the count of the restores is the measure.
**Priority:** High

### TC-SA-23-02-014 — Restore duration: the duration (the duration of the restore, the time); the duration is the time
**Type:** Positive
**Covers:** 2.2 → Restore duration: the duration (the duration of the restore, the time)
**Preconditions:** Multiple restores with recorded durations exist.
**Steps:**
1. View the restore duration: the duration (the duration of the restore, the time) — verify the restore duration is the duration.
2. Verify the duration shows the time taken for each restore.
3. Verify the recorded duration matches the actual elapsed time (start to completion).
**Expected Result:** The restore duration is shown — the duration of the restore, the time, is the time.
**Priority:** High

### TC-SA-23-02-015 — Restore view: the view (the restores, the backups, the scopes, the dates); the recovery is managed
**Type:** Positive
**Covers:** 2.2 → Restore view: the view (the restores, the backups, the scopes, the dates); Rule: the system is restored (the restores, the backups, the scopes, the dates); the recovery is managed
**Preconditions:** Multiple restores exist.
**Steps:**
1. View the restores: the view (the restores, the backups, the scopes, the dates) — verify the system is restored.
2. Verify each restore shows the backup, the scope, and the date.
3. Verify the recovery is managed (view, select, restore, verify).
**Expected Result:** The restores are viewed — the restores, the backups, the scopes, and the dates are visible; the recovery is managed.
**Priority:** High

### TC-SA-23-02-016 — Restore from backup is audit-logged with the restore, backup, and timestamp
**Type:** Positive
**Covers:** 2.2 → Audit logging of the restore from backup; Rule: restore from backup is audit-logged with the restore, backup, and timestamp
**Preconditions:** Super Admin has performed a restore.
**Steps:**
1. Open the audit trail and filter by "restore".
2. Verify entries show the restore, the backup, and the timestamp.
**Expected Result:** The restore from backup is audit-logged with the restore, backup, and timestamp.
**Priority:** Critical

## 2.3 Recovery Point and Recovery Time Tracking

### TC-SA-23-02-017 — Recovery point: the point (the point, the backup, the date); the point is the position
**Type:** Positive
**Covers:** 2.3 → Recovery point: the point (the point, the backup, the date); Rule: the recovery point is the moment (the point, the backup, the date); the point is the position
**Preconditions:** Backups with recorded recovery points exist.
**Steps:**
1. Open Backup & Data Export → Disaster Recovery → Recovery Point and Recovery Time Tracking.
2. View the recovery point: the point (the point, the backup, the date) — verify the recovery point is the moment.
3. Verify the recovery point shows the backup and the date.
4. Verify the recovery point equals the timestamp of the data captured in the backup (the moment the system can be returned to).
**Expected Result:** The recovery point is tracked — the point, the backup, and the date are the position.
**Priority:** Critical

### TC-SA-23-02-018 — Backup: the backup (the backup, the scope, the date); the backup is the safety
**Type:** Positive
**Covers:** 2.3 → Backup: the backup (the backup, the scope, the date); Rule: the backup is the copy (the backup, the scope, the date); the backup is the safety
**Preconditions:** Multiple backups with recovery points exist.
**Steps:**
1. Select the backup: the backup (the backup, the scope, the date) — verify the backup is the copy.
2. Verify the backup shows the scope and the date.
3. Verify each recovery point is tied to exactly one backup.
**Expected Result:** The backup is selected — the backup, the scope, and the date are the safety.
**Priority:** High

### TC-SA-23-02-019 — Recovery time: the time (the time, the restore, the date); the time is the length
**Type:** Positive
**Covers:** 2.3 → Recovery time: the time (the time, the restore, the date); Rule: the recovery time is the duration (the time, the restore, the date); the time is the length
**Preconditions:** Restores with recorded recovery times exist.
**Steps:**
1. View the recovery time: the time (the time, the restore, the date) — verify the recovery time is the duration.
2. Verify the recovery time shows the restore and the date.
3. Verify the recovery time matches the actual restore duration recorded for that restore.
**Expected Result:** The recovery time is tracked — the time, the restore, and the date are the length.
**Priority:** High

### TC-SA-23-02-020 — Restore: the restore (the restore, the backup, the date); the tracking is the measurement
**Type:** Positive
**Covers:** 2.3 → Restore: the restore (the restore, the backup, the date)
**Preconditions:** Multiple restores exist.
**Steps:**
1. View the restores in tracking: the restore (the restore, the backup, the date) — verify each restore is measured.
2. Verify each restore shows the backup and the date.
3. Verify every completed restore appears in the tracking (no restore is missing from the measurement).
**Expected Result:** The restores are tracked — the restore, the backup, and the date are the measurement; every restore is measured.
**Priority:** High

### TC-SA-23-02-021 — Recovery point count: the count (the count of the recovery points); the count is the measure
**Type:** Positive
**Covers:** 2.3 → Recovery point count: the count (the count of the recovery points)
**Preconditions:** Multiple recovery points exist.
**Steps:**
1. View the recovery point count: the count (the count of the recovery points) — verify the recovery point count is the measure.
2. Verify the count matches the actual number of recovery points.
3. Complete a new backup — verify the count increments.
**Expected Result:** The recovery point count is shown — the count of the recovery points is the measure.
**Priority:** High

### TC-SA-23-02-022 — Recovery time average: the average (the average of the recovery times, the time); the average is the baseline
**Type:** Edge
**Covers:** 2.3 → Recovery time average: the average (the average of the recovery times, the time); Rule: the recovery time average is the norm (the average of the recovery times, the time); the average is the baseline
**Preconditions:** Multiple recovery times exist; a state with zero completed restores (zero-division edge) is also prepared.
**Steps:**
1. View the recovery time average: the average (the average of the recovery times, the time) — verify the recovery time average is the norm.
2. Verify the average equals the mean of the recorded recovery times (exact arithmetic, no rounding drift).
3. Check the zero-restore state — verify the average shows a documented "no data" value (never a division error, NaN, or crash).
**Expected Result:** The recovery time average is shown — the average of the recovery times, the time, is the baseline; zero-restore states never produce division errors.
**Priority:** High

### TC-SA-23-02-023 — Recovery view: the view (the points, the backups, the times, the dates); the tracking is managed
**Type:** Positive
**Covers:** 2.3 → Recovery view: the view (the points, the backups, the times, the dates); Rule: the recovery is measured (the points, the backups, the times, the dates); the tracking is managed
**Preconditions:** Multiple recovery points and times exist.
**Steps:**
1. View the recovery: the view (the points, the backups, the times, the dates) — verify the recovery is measured.
2. Verify each entry shows the point, the backup, the time, and the date.
3. Verify the tracking is managed (view, compare, trend, report).
**Expected Result:** The recovery is viewed — the points, the backups, the times, and the dates are visible; the tracking is managed.
**Priority:** High

### TC-SA-23-02-024 — Recovery point and time tracking is audit-logged with the point, time, and timestamp
**Type:** Positive
**Covers:** 2.3 → Audit logging of the recovery point and time tracking; Rule: recovery point and time tracking is audit-logged with the point, time, and timestamp
**Preconditions:** Super Admin has viewed recovery point and time tracking.
**Steps:**
1. Open the audit trail and filter by "recovery tracking".
2. Verify entries show the point, the time, and the timestamp.
**Expected Result:** The recovery point and time tracking is audit-logged with the point, time, and timestamp.
**Priority:** Critical
