Per-surface parity harness for the Step 2-4 migrations#372
Draft
Firehed wants to merge 16 commits into
Draft
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #372 +/- ##
============================================
+ Coverage 97.61% 98.12% +0.51%
Complexity 1696 1696
============================================
Files 105 105
Lines 4271 4271
============================================
+ Hits 4169 4191 +22
+ Misses 102 80 -22 ☔ View full report in Codecov by Harness. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Slice SP.1 — Per-surface parity harness + branch-coverage gate
Adds the corpus-wide golden harness that lets the Step 2–4 strangler migrations be
proven behavior-preserving.
TypeGraphParityTestcovers member resolution only;this covers the four surfaces those steps move consumers onto.
What's here
GoldenCodec(deterministic, portable JSON encoding +path relativization) and the
AssertsGoldentrait (UPDATE_GOLDENS=1torecapture, diff otherwise), each with self-tests proving a diverged surface goes
red and update-mode recaptures.
deterministic corpus (in-repo fixtures + the locked
psr/http-message; reflectionbuilt-ins covered by stable-subset assertions, not frozen):
ClassRepository::get()NamespaceCatalog::childrenOf()SymbolIndex::findByPrefix()composer parity-coverageruns only thefour surface tests with coverage restricted to the migrated surface classes, so an
unexecuted line is a corpus gap. The corpus drives every surface class to 100%
except a handful of provably-unreachable defensive guards, enumerated in
tests/Parity/README.md.Acceptance criteria (Step P)
childrenOf, prefix-search, write-path), so a later step can rewrite one surface's golden while the others stay frozencomposer parity-coverage, scoped to the surface classes)Fixtures\testsconfirmed a real dir;ClassModifiersmulti-class file; anon-class members correctly skipped)Notes for the reviewer
/review-slice(per the maintainer'sdecision): pcov measures line coverage; the adversarial pass verifies the corpus
actually catches a regression (name a mutation, confirm a golden goes red).
uncovered lines are pre-existing defensive/dead guards in existing production
(parser
ast === nullunder a collecting handler,file_get_contentsafteris_readable, synthetic-autoload-map-only branches, aConstantnameKind arm theextractor never emits) — documented in the README, not new code.
churn on any edit above a symbol), and the enumeration corpus is narrowed to stable
namespaces (locked vendor, single PSR-0/classmap fixtures, the
Fixtures\Modelsubtree) so unrelated fixture growth cannot churn it. This is a permanent
regression net (Step Z requires it green; it is not on the Teardown ledger).
Candidate closes
None — SP.1's manifest
Closescolumn is empty.