mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-11-16 05:41:03 +01:00
Support Array in OpenApi Examples (#664)
This commit is contained in:
1 parent
6c65dfcff6
commit
74edad517b
2 files changed
+104
-1
No files matched your search
@@ -209,7 +209,14 @@ namespace WireMock.Net.OpenApiParser.Mappers
|
||||
var writer = new OpenApiJsonWriter(outputString);
|
||||
any.Write(writer, OpenApiSpecVersion.OpenApi3_0);
|
||||
|
||||
return JObject.Parse(outputString.ToString());
|
||||
if (any.AnyType == AnyType.Array)
|
||||
{
|
||||
return JArray.Parse(outputString.ToString());
|
||||
}
|
||||
else
|
||||
{
|
||||
return JObject.Parse(outputString.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
private IDictionary<string, object> MapHeaders(string responseContentType, IDictionary<string, OpenApiHeader> headers)
|
||||
|
||||
Reference in new issue
Block a user