# V1 Block 25 — Scheduler Integration Tests **Purpose**: End‑to‑end tests. > **Note for Codex**: Follow tasks exactly; avoid exploratory calls when tasks specify names/files/tests. ## Chunk 25.1 — Integration test harness Recommended level: **HIGH** Status: Complete on 2026-06-26. ### Tasks 1. Add test file `integration/scheduler_flow_test.dart` in `packages/scheduler_integration_tests`. 2. Spin up InMemory repos, schedule engine, fake notification adapter. 3. Create tasks, invoke scheduler, assert placements, save via SQLite adapter, reload and assert persistence. ### Acceptance criteria 1. Test passes on CI in < 2s runtime. ### Completed implementation 1. Added package `packages/scheduler_integration_tests`. 2. Added required integration test file `integration/scheduler_flow_test.dart`. 3. Added test wrapper `test/scheduler_flow_test.dart` so package-level `dart test` runs the integration flow. 4. Integration flow seeds `InMemoryTaskRepository`, invokes `SchedulingEngine.insertBacklogTaskIntoNextAvailableSlot`, asserts task placement, schedules through `FakeNotificationAdapter`, saves through `SqliteTaskRepository`, reloads, and asserts persisted schedule/status. 5. Added an in-test runtime guard asserting the flow completes in under 2 seconds. 6. Wired integration test into the root test wrapper. ### Verification 1. `dart pub get`: passed. 2. `dart format test/scheduler_core_test.dart packages/scheduler_integration_tests`: passed. 3. `cd packages/scheduler_integration_tests && dart analyze`: passed, no issues found. 4. `cd packages/scheduler_integration_tests && dart test`: passed, 1 test. 5. `dart analyze`: passed, no issues found. 6. `dart test`: passed, 333 tests. 7. `scripts/test.sh`: not present or not executable. ---