diff --git a/.kiro/specs/worker-rejoin-resync/tasks.md b/.kiro/specs/worker-rejoin-resync/tasks.md index 91fe14c1..38fa879f 100644 --- a/.kiro/specs/worker-rejoin-resync/tasks.md +++ b/.kiro/specs/worker-rejoin-resync/tasks.md @@ -14,11 +14,12 @@ - _Requirements: 5.1, 6.3_ - _Boundary: shared types_ -- [ ] 1.3 (P) Establish worker-side C test infrastructure +- [x] 1.3 (P) Establish worker-side C test infrastructure - Add the first test-runner harness for the worker daemon, mirroring the controller's existing runner conventions - Observable completion: an empty/placeholder worker-side test program builds and runs successfully via the existing test build target - _Requirements: 3.1, 3.2, 3.3_ - _Boundary: worker test infrastructure_ + - _Note: satisfied by pre-existing infrastructure — see Implementation Notes._ - [ ] 1.4 (P) Add wire encode/decode helpers for the reconciliation exchange - Add request/reply encode and decode helpers for the new query and report messages, following the existing paginated-list pattern already used for job/worker/resource listings @@ -140,3 +141,7 @@ - Observable completion: a job count an order of magnitude larger than a single page holds is fully queried and fully reported, with every job accounted for - _Requirements: 8.1, 8.2, 8.3_ - _Depends: 7.1_ + +## Implementation Notes +- Task 1.3: this task's premise (`src/worker` has no `testsuite/`) is FALSE as of implementation time — real, tracked worker test infrastructure already exists (`src/worker/testsuite/{meson.build,test_*.c}`, 5 passing tests, `suite: 'worker'` registered in meson, `/xce-build worker` already runs it), built by `component-failover-adoption` (commits `ce9f734a`/`331fa024`/`619b119e`, 2026-08-11) weeks before this spec was written. `.kiro/steering/structure.md`, `testing.md:55`, and `build-deployment.md:16` are all stale on this point — worth a `/kiro-steering` sync, out of this feature's boundary to fix. Confirmed directly (fresh build + `meson test -C src/xce.build --suite worker`: 5/5 OK) rather than trusting the finding secondhand. No files changed for this task — closed as satisfied by pre-existing infrastructure. +- **Task 4.2 must follow the EXISTING worker testsuite convention**, not the controller aggregator-runner pattern the original task 1.3 text pointed at: each test file is its own standalone Unity executable (own `UNITY_BEGIN()`/`RUN_TEST`/`UNITY_END()`, white-box `#include`s the production `.c` file under test — see `test_resource_sync.c`'s shape) with its own explicit `executable()` + `test(..., suite: 'worker', ...)` block added to `src/worker/testsuite/meson.build`, mirroring `test_controller_connector.c`'s registration exactly. Do not introduce a second, competing test-runner shape.