Normalize annotation values in XQSuite assertEquals for XML comparison#6085
Closed
joewiz wants to merge 1 commit intoeXist-db:developfrom
Closed
Normalize annotation values in XQSuite assertEquals for XML comparison#6085joewiz wants to merge 1 commit intoeXist-db:developfrom
joewiz wants to merge 1 commit intoeXist-db:developfrom
Conversation
…comparison (eXist-db#4327) When comparing XML nodes in test:assertEquals, the actual result was normalized (whitespace stripped) but the expected value from the annotation was not. This caused assertions with whitespace around XML in %test:assertEquals annotations to fail unexpectedly. Now both values are normalized before comparison via deep-equal. Closes eXist-db#4327 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
f0a82e2 to
8d246b1
Compare
Open
3 tasks
Member
Author
|
[This comment was co-authored with Claude Code. -Joe] Closing — superseded by #6207 (v2/xq31-compliance-fixes). This work has been consolidated into a clean v2/ branch as part of the eXist-db 7.0 PR reorganization. The new PR includes all commits from this PR plus additional related work, with reviewer feedback incorporated where applicable. See the reviewer guide for the full context. |
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.
Summary
%test:assertEqualsfailing when the annotation value contains whitespace around XML (e.g., newlines before/after<span>)test:normalize) but the expected value from the annotation was not, causingdeep-equalto failCloses #4327
Test plan
%test:assertEqualsannotation around XML element🤖 Generated with Claude Code