Repository navigation
test: pin anonymizer names, UID rewrites, prototype safety, and small value behaviors - #529
Merged
Merged
Conversation
… value-handling behaviors 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 closes out the regression bank: the last set of suites pinning behavior that already passes on this branch, with anything still broken checked in as an
it.skipnaming its issue. With this merged, the bank covers every issue-derived test that passes against the current branch. The fourteen suites that exercise the event stream arrive with the engine code itself, and two suites pinning fixed logging behavior (#368 and #457) travel with those fixes.Six behavior areas across seven files.
test/issues/issue345-anonymizer-names.test.js— the anonymizer. For #172 it pins the public surface:cleanTagsandgetTagsNameToEmptyare exported, andcleanTagsreplaces PatientName/PatientID and empties the rest of its list. #345 is the sharp edge: many entries in that to-empty list aren't real dictionary keywords (singular/plural slips, ad-hoc abbreviations like "RefStudySeq"), so the anonymizer silently skips them and the data they were meant to scrub survives. 103 of the 221 names fail to resolve — that's the skipped KNOWN GAP #345. A green sanity test pins that the five corrected keywords the issue proposes do exist, so fixing the list needs no dictionary changes:test/issues/issue315-uid-rewrite.test.js— #315: changing an instance UID and rewriting must yield a valid file (upstream, the re-read threw "Invalid DICOM file, expected header is missing"). Both flows are pinned green: the issue's own repro flow with a new StudyInstanceUID, and the documenteddatasetToDictpattern where a new SOPInstanceUID must land in both the dataset and the file meta.test/issues/issue10-prototype-pollution.test.js— #10: with an enumerable property added toObject.prototype(the old meteor-based OHIF environment), the full naturalize → denaturalize → write → re-read cycle must succeed with no "__polluted" key materializing anywhere in the output trees. Green.test/issues/issue356-private-creator-range.test.js— #356:Tag.isPrivateCreatorshould accept elements 0x0010–0x00FF of odd groups and nothing else; that's where private creator elements (the labels that reserve a private block) live per the standard. The valid range and the obvious rejections are green; the current check also admits the reserved 0x0001–0x000F range, which is the skipped KNOWN GAP #356.test/issues/issue46-lt-single-valued.test.js— #46: LT (Long Text) is a single-valued VR, so a backslash inside it is ordinary text, not a value separator. Round trips with backslash-bearing history text and Windows paths stay one value. Green, no skips.test/issues/issue505-unit2codingvalue.test.js— #505: the TID300unit2CodingValuemapping table. "mm", "cm2", and "HU" map to their proper UCUM codes (green); plain "cm" is missing from the table and falls through to the arbitrary-unit branch as[arb'U]{cm}, which is the skipped KNOWN GAP #505.test/issues/issue78-unobtainable-fixtures.test.jsis different: its skips are BLOCKED placeholders, not known gaps. They spell out exactly what will be asserted for #78 (RLE SEG read failures) and #86 (palette color LUT read failures) the day a usable fixture lands — both upstream fixture links are dead. A third placeholder covers #363, whose attachment does reproduce but carries real patient identity and failed PHI vetting, so it was deleted rather than cached (#347 is likewise fixture-dead).🤖 Generated with Claude Code