[PR #690] [CLOSED] Add wildcard matching support for path and header parameters in OpenAPI #1036

Closed
opened 2025-12-29 08:34:25 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/wiremock/WireMock.Net/pull/690
Author: @JanuszRybinski
Created: 11/21/2021
Status: Closed

Base: masterHead: master


📝 Commits (1)

  • 9cf1581 Add wildcard matching support for path and header parameters in OpenAPI

📊 Changes

1 file changed (+17 additions, -5 deletions)

View changed files

📝 src/WireMock.Net.OpenApiParser/Mappers/OpenApiPathsMapper.cs (+17 -5)

📄 Description

Hi,
I'm using WireMock.Net with an OpenAPI parser, but when generating the mappings the behavior of matching headers and parameters in the query string is set permanently (ExactMatcher). I have a proposal to use the settings to control the matching behavior:

var settings = new WireMockOpenApiParserSettings
{
     PathPatternToUse = ExampleValueType.Wildcard,
     HeaderPatternToUse = ExampleValueType.Wildcard
};

However, I am not sure if these two parameters can be used for this purpose :) I am asking for your opinion and if it is OK, please include it in the solution.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/wiremock/WireMock.Net/pull/690 **Author:** [@JanuszRybinski](https://github.com/JanuszRybinski) **Created:** 11/21/2021 **Status:** ❌ Closed **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (1) - [`9cf1581`](https://github.com/wiremock/WireMock.Net/commit/9cf1581c04a798e2245c79ce121fa3a6c63fdbc4) Add wildcard matching support for path and header parameters in OpenAPI ### 📊 Changes **1 file changed** (+17 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `src/WireMock.Net.OpenApiParser/Mappers/OpenApiPathsMapper.cs` (+17 -5) </details> ### 📄 Description Hi, I'm using WireMock.Net with an OpenAPI parser, but when generating the mappings the behavior of matching headers and parameters in the query string is set permanently (ExactMatcher). I have a proposal to use the settings to control the matching behavior: ```c# var settings = new WireMockOpenApiParserSettings { PathPatternToUse = ExampleValueType.Wildcard, HeaderPatternToUse = ExampleValueType.Wildcard }; ``` However, I am not sure if these two parameters can be used for this purpose :) I am asking for your opinion and if it is OK, please include it in the solution. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 08:34:25 +01:00
adam closed this issue 2025-12-29 08:34:25 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/WireMock.Net#1036