Skip to content

Use String to specify custom HTTP method in mock request #8592

@eleftherias

Description

@eleftherias

In Spring Framework 5.2.7, MockServerHttpRequest will accept a custom HTTP method as a String parameter.
Going forward we should use

MockServerHttpRequest.method("CUSTOM-HTTP-METHOD", "/")

when testing a request with a custom HTTP method.

The test matchesRequireCsrfProtectionWhenNonStandardHTTPMethodIsUsed will need to be updated.

Reference: spring-projects/spring-framework#25109

Metadata

Metadata

Assignees

Labels

in: configAn issue in spring-security-configstatus: blockedAn issue that's blocked on an external project changetype: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions