Tracks the multi-phase restructure of the phevcore build system and project layout. Each phase is one PR.
- Add
CMakePresets.json(dev / release / ci) - Remove
splint.cmakestub - Fix GitHub Actions CI to run tests natively
- Update Dockerfile to use presets
- Remove dead files (
.travis.yml,runtests.bat,.gitmodules, CSV) - Expand
.gitignore - Add
.clang-format - Update
AGENTS.mdto reflect changes
- Choose test framework: greatest (v1.5.0)
- Add framework via FetchContent
- Convert
test_phev_core.c(82 tests — 66 pass, 16 fail from previously-unwired tests) - Convert
test_phev_pipe.c(31 tests — 21 pass, 10 fail from previously-unwired tests) - Convert
test_phev_service.c(70 tests — 60 pass, 9 fail, 1 skip from previously-unwired tests) - Convert
test_phev_model.c(8 tests — all pass) - Convert
test_phev.c(2 tests — all pass) - Convert
test_phev_register.c(14 tests — all pass) - Wire all previously-unwired test functions (35 fail + 1 skip are pre-existing bugs, not regressions)
- Triage orphaned files:
test_phev_config.c— converted to greatest (12 tests, all pass), fixturetest/config.jsoncreatedtest_phev_controller.c— deleted (requires CMock + missing sourcephev_controller.c)test_phev_response_handler.c— deleted (empty, 0 tests)
- Delete all
run_*.cUnity shims - Delete
test_runner.cand Unity FetchContent (Unity was already removed) - Verify all 219 tests run across 7 suites — 183 pass, 35 fail, 1 skip (zero regressions)
- Fixed
include/logger.hhexdump()stack-buffer-underflow (line 89) - Added missing
phev_core_validateChecksumXORdeclaration toinclude/phev_core.h - Skipped
test_phev_service_jsonInputTransformer— pre-existing segfault from NULL pipe context
- Move
src/intosrc/msg/+src/phev/ - Move
include/intoinclude/msg/+include/phev/ - Update all
#includedirectives (79 directives across 24 files) - Split CMake into two targets:
msg_core(static) +phev(static, linksmsg_core) - Gate dead transport backends (
msg_gcp_mqtt,msg_mqtt_paho) behindBUILD_TRANSPORT_BACKENDSoption - Update install rules for new directory layout
- Tests remain in
test/(no msg-layer tests exist; all 7 suites test phev) - Dockerfile and CI already use presets — no changes needed
- Update
AGENTS.mdto reflect restructure
Goal: fix all 36 tests that were SKIPped (pre-existing bugs from previously-unwired test functions) and reduce the skip count to zero.
-
phev_core_getType()— XOR-decode the type byte before classifying (src/phev/phev_core.c) -
phev_core_encodeMessage()— apply XOR to encoded bytes (src/phev/phev_core.c) -
phev_service_jsonInputTransformer()— guard against NULLctx->pipe(src/phev/phev_service.c) -
phev_pipe_outputChainInputTransformer()— use decodedphevMessage->XORinstead ofmessage->ctxfor XOR detection; return decoded message when XOR is active (src/phev/phev_pipe.c) -
phev_pipe_commandResponder()— propagate XOR frommessage->ctxtophevMsg.XORso response is correctly encoded (src/phev/phev_pipe.c) -
phev_core_xorDataOutbound()/phev_core_XOROutboundMessage()— usemessage->lengthinstead ofdata[1]+2to handle concatenated messages (src/phev/phev_core.c) -
phev_service_validateCommand()— add missing "update" operation validation (src/phev/phev_service.c)
- Group 1 (4 tests): fix checksums and expected data for XOR-encoded messages
- Group 2 (5 tests): fix expected XOR values and command/ack expectations
- Group 3 (4 tests): fix expected ping constant (0xf6 → 0xf9)
- Group 4 (3 tests): fix expected data arrays for XOR encoding
- Group 6 (5 tests): update expected data and checksum for XOR encoding
- Group 7 (4 tests): fix expected bytes for service-layer encoding
- Group 10 (1 test, line 263):
validateCommand()missing "update" operation
- Group 5 (3 tests):
commandXORpropagation through pipe context - Group 6 (2 tests):
outputChainInputTransformerwith XOR - Group 7 (1 test + 1 bonus): XOR handling with NULL pipe context / ping response
- Group 8 (2 tests):
sendMac/start_my18wiring — fixxorDataOutboundlength - Group 9 (1 test):
waitForConnectionretry loop — add failing connect stub
- Started: 36 SKIPped tests (16 + 10 + 10)
- Fixed: 36 (all)
- Remaining: 0
- All 219 tests pass across 7 suites, 0 fail, 0 skip
- Remove dead transport source files (
msg_gcp_mqtt.*,msg_mqtt_paho.*) - Remove stale
config.h(unused) - Remove
BUILD_TRANSPORT_BACKENDSoption and install block fromCMakeLists.txt - Clean up stale remote branches (deleted 6: phase1-3, add-license-1, register_fix, robustxor)
- Clean up stale local branches (deleted phase1-3)
- Update
AGENTS.mdto reflect all-tests-passing and removal of transport backends - Final CI verification — dev preset build + all 219 tests pass, release preset builds clean