You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "youngkermit8-coder (via GitHub)" <gi...@apache.org> on 2026/08/11 09:19:15 UTC

[PR] test: make tool schema fixtures line-ending independent [rocketmq-dashboard]

youngkermit8-coder opened a new pull request, #1705:
URL: https://github.com/apache/rocketmq-dashboard/pull/1705

   ## Summary
   
   - normalize the canonical AI tool catalog fixture to LF before mutating it
   - replace indentation-sensitive text blocks with explicit YAML fragments
   - assert that each invalid schema marker was inserted before loading the catalog
   
   ## Root cause
   
   On CRLF checkouts, `ClassPathResource` preserves the catalog's CRLF line endings while the search text passed to `String.replace(...)` contains LF line endings. The replacements silently returned the unchanged valid catalog, so the two startup schema-validation tests failed without exercising their intended invalid inputs.
   
   ## Impact
   
   The AI tool gateway schema-validation tests now exercise unresolved references and invalid JSON Schema types consistently across LF and CRLF environments. The mutation assertions also prevent future fixture drift from turning these tests into silent no-ops.
   
   Closes #1703
   
   ## Validation
   
   - `mvn -Dtest=ToolGatewayServiceTest test` — 27 tests passed
   - `mvn test` — 958 tests passed
   - Checkstyle — 0 violations
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] test: make tool schema fixtures line-ending independent [rocketmq-dashboard]

Posted by "lizhimins (via GitHub)" <gi...@apache.org>.
lizhimins merged PR #1705:
URL: https://github.com/apache/rocketmq-dashboard/pull/1705


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org