Skip to content

fix: make XXE protection test locale-resilient#2102

Merged
triceo merged 3 commits intoTimefoldAI:mainfrom
Dolverin:fix/locale-resilient-xxe-test
Feb 15, 2026
Merged

fix: make XXE protection test locale-resilient#2102
triceo merged 3 commits intoTimefoldAI:mainfrom
Dolverin:fix/locale-resilient-xxe-test

Conversation

@Dolverin
Copy link
Contributor

Summary

  • The GenericJaxbIOTest.readOverridingNamespaceIsProtectedFromXXE test asserts on the English error message "DOCTYPE is disallowed", which fails on non-English JVM locales (e.g. de_DE produces "DOCTYPE ist nicht zulässig")
  • Changed the assertion to match "disallow-doctype-decl" instead — the XML parser feature name, which is locale-independent and always present in the SAXParseException message

Test plan

  • Verified test passes on de_DE locale (previously failed)
  • Verified test passes on en_US locale (still works)
  • Tested with JDK 21 (Temurin 21.0.10)

🤖 Generated with Claude Code

Dolverin and others added 2 commits February 11, 2026 19:01
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The GenericJaxbIOTest.readOverridingNamespaceIsProtectedFromXXE test
asserted on the localized error message "DOCTYPE is disallowed", which
fails on non-English JVM locales (e.g. de_DE: "DOCTYPE ist nicht
zulässig"). Assert on the feature name "disallow-doctype-decl" instead,
which is locale-independent and always present in the SAXParseException
message.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Collaborator

@triceo triceo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the contribution, @Dolverin!
LGTM once the CLAUDE.md file is removed.

@triceo triceo added this to the v2.0.0.CR1 milestone Feb 15, 2026
@triceo triceo merged commit 13b639c into TimefoldAI:main Feb 15, 2026
16 of 18 checks passed
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants