Repository navigation
test: verify comment-only configuration identity invariance - #134
Conversation
ip332
left a comment
There was a problem hiding this comment.
Independent technical review: GO / approved for squash merge at exact head 5ed0ca6db9a0323c61ccd43aba721a0535cc3bc3.
Reviewed tests/tools/schema_compiler_tool_test.cpp including the new CommentOnlyEditsPreserveConfigurationIdentityAndQbsBytes regression. It uses existing CLI/QBS helpers and temporary copies of the authoritative configuration fixture, exercises comments in the root and both imported units, checks full 128-bit schema_id, entire --describe output with pinned hierarchical record IDs, and both minimal and reflective QBS byte equality. All phases repeat deterministically. The u16→u32 valid wire-change control correctly changes schema_id and both QBS images without requiring record-ID changes. The reported corrupted-capture mutation failed the intended assertion and was restored. Other changes in this file are mechanical formatting. No production/format/epoch change is introduced.
Verified exact-head workflow 45083985478 completed successfully: Build and test 75/75 Linux CTests, coverage 70/70 with baseline guard, clang-tidy and Cortex-M. Benchmarks skipped by normal PR policy. No merge-blocking finding. Recommend squash merge with head-SHA check, confirm issue #130 closes, then verify post-merge CI. Published v0.1.31-rc.1 remains unchanged.
This is a technical-review COMMENT rather than formal APPROVE because the connected GitHub identity owns the PR. No merge performed.
Closes #130
Adds
SchemaCompilerToolTest.CommentOnlyEditsPreserveConfigurationIdentityAndQbsBytesusing temporary copies of the existing small description fixture. The real compiler captures the full 128-bit--print-schema-id, complete--describeoutput with both pinned record IDs, and minimal/reflective QBS bytes. Standalone and inline comments are added before/between declarations in the configuration root and both imported files. Baseline, comment-only and wire-change phases are each compiled twice.Comment-only results:
ef38354d6020a83018197caca9a2757a.m.Alpha = 0x00010001,m.Zeta = 0x00010002remain unchanged.Negative control: changing only
m.Alpha.valuefromu16tou32succeeds and changes schema_id todd42edaaff5ce856f95d1c48de6615ce. Both QBS images change (249/295 bytes), while the record IDs remain unchanged. The changed configuration also regenerates deterministically.Mutation check: temporarily corrupted one hex digit of the captured comment-only identity. The new test failed at
actual.schema_id == expected.schema_id; restored the temporary mutation byte-for-byte and reran successfully. No mutation is committed.Only the existing CLI test source changes. The configured clang-format commit hook also normalized existing formatting in that touched file; those surrounding edits are mechanical formatting. No new parser, identity algorithm, backend generation or runtime behavior is introduced.
Validation:
5ed0ca6db9a0323c61ccd43aba721a0535cc3bc3via scripts/quarry-validate.Baseline: #133 squash-merged as
51f11d3243b41cdb4b31e7606f28f1a39b435e2b, #129 closed, all five post-merge CI jobs passed in run 45080145229 before implementation began. Published v0.1.31-rc.1 remains unchanged. Auto-merge is disabled; independent review required.