Browse Source

docs: add closed-app delivery acceptance criteria

Add comprehensive testing requirements for closed-app scenarios:
- Close app (swipe away), screen off → exact alarm delivers via DailyNotificationReceiver
- Exact alarm denied → WorkManager path fires with degraded timing UI
- Reboot device with app closed → BootReceiver reschedules idempotently

Add corresponding Test Matrix entries:
- Closed app delivery: exact alarm path with receiver delivery
- Closed app fallback: WorkManager path with degraded timing
- Closed app reboot: UPSERT prevents duplicate schedules

These criteria ensure closed-app delivery works correctly in both exact alarm and fallback paths, with proper logging and UI feedback.
master
Matthew Raymer 2 days ago
parent
commit
58617c98f4
  1. 6
      docs/android-app-improvement-plan.md

6
docs/android-app-improvement-plan.md

@ -967,6 +967,9 @@ interface ScheduleResponse {
- [ ] Test UI modularized into scenarios
- [ ] At least 2 scenarios run as automated tests
- [ ] Instrumentation tests cover critical paths
- [ ] **Close app (swipe away)**, screen off → exact alarm delivers via `DailyNotificationReceiver`; status matrix remains green; log shows `EVT_SCHEDULE_OK` → receiver → notification
- [ ] **Exact alarm denied** → schedule; with app closed and device idle, WorkManager path eventually fires; UI shows "**Degraded timing (Doze)**" and logs `EVT_DOZE_FALLBACK_TAKEN`
- [ ] **Reboot device** with app closed → `BootReceiver` reschedules idempotently (UPSERT key), single notification posts at the next window
### Security
- [ ] All PendingIntents are immutable unless mutation is required
@ -1064,6 +1067,9 @@ By following this plan, the test app will become more maintainable, reliable, an
| Timezone change | TimeChangeReceiver | Change device timezone | One rehydrated schedule, no duplicates |
| Manual clock skew | TimeChangeReceiver | Move clock +10m (no timezone) | Rescheduler recompute without duplicates; status remains green |
| Missing small icon | scheduleDailyNotification | No small icon set | Canonical error or logged warning; no silent drop |
| Closed app delivery | scheduleDailyNotification + DailyNotificationReceiver | App closed, screen off | Exact alarm delivers via receiver; log shows `EVT_SCHEDULE_OK` → receiver → notification |
| Closed app fallback | scheduleDailyNotification + WorkManager | App closed, device idle, exact alarm denied | WorkManager fires eventually; UI shows "Degraded timing (Doze)" |
| Closed app reboot | BootReceiver | App closed, device reboot | Single notification posts at next window; UPSERT prevents duplicates |
## Error Codes (canonical)

Loading…
Cancel
Save