Skip to content

Provide XML-based assertions in WebTestClient [SPR-16741] #21282

@spring-projects-issues

Description

@spring-projects-issues

Eric Deandrea opened SPR-16741 and commented

WebTestClient is missing the ability to perform assertions against XML content like you can do with MockMvc (like with MockMvcResultMatchers.xpath). This is essential for building enterprise applications which have to support both XML & JSON.

I propose we add similar things to org.springframework.test.web.reactive.server.WebTestClient.BodyContentSpec as well as a new XpathAssertions class (similar to JsonPathAssertions) that ties into org.springframework.test.util.XpathExpectationsHelper.


Affects: 5.0.5

Issue Links:

Referenced from: commits 0c62d6b, 2734f01

Metadata

Metadata

Assignees

Labels

in: testIssues in the test modulein: webIssues in web modules (web, webmvc, webflux, websocket)type: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions