Repository navigation
test: add the issue triage catalog and part10 walker for the regression bank - #524
Merged
Merged
Conversation
…regression bank Co-Authored-By: Claude Fable 5 <[email protected]>
|
🎉 This PR is included in version 1.0.0-beta.1 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
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.
This PR begins the green regression bank — step 4 of section 6 in RELEASE_PLAN.md. The idea behind the bank: every upstream dcmjs issue that was harvested for the rewrite gets a triage record, and the ones that describe real, reproducible behavior get a pinned test. This PR lands the two shared pieces the bank needs before any of those tests can arrive: the triage catalog and a byte-level file walker.
The catalog is
test/issues/catalog.json. It's the triage record for all 172 upstream issues. Each entry carries the issue's metadata (number, title, state, an excerpt) plus atriageblock with a category, an area, a disposition, a status, and the test file it maps to when one exists. It's data, not code, so it lands in its own declared commit.The walker is
test/issues/part10Walker.js— a small standalone helper for inspecting written DICOM Part 10 files (the standard file format: 128-byte preamble, "DICM" magic, then the File Meta group and the dataset) element by element. The important design choice is that it deliberately re-parses writer output with independent code rather than the library's own reader. That way, structural assertions — tag ordering, pad-byte placement, fragment counts, sequence length encoding — are made against the actual bytes, standing in for the external consumers (pydicom, DCMTK, dcm4che) that the upstream issues cite. It exportsdatasetStart,readElementHeader,walkTopLevelElements,findElement, andparseEncapsulatedPixelData, and its scope is intentionally narrow: Explicit VR Little Endian only, which covers every synthetic fixture in the suite.Here's how the bank's tests use it — this is from the issue 365 test (writer emitting tags out of order), which lands in a later batch:
The test files themselves follow in five batched PRs, each sized to stay within the review budget. Issues whose triage status is
gaportriageddon't get test files yet — those arrive later, together with the code that fixes them, per section 7 of the plan.🤖 Generated with Claude Code