From b50a07d348dc20c63727b4400149a18400b76ab8 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 1 Oct 2025 01:27:43 +0000 Subject: [PATCH 1/6] Initial plan From 6966be594a2cf0a4da7b1526e0e79da3ce224024 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 1 Oct 2025 01:35:33 +0000 Subject: [PATCH 2/6] Add DataValue and SerializedValue properties to OpenApiExample Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --- .../Models/Interfaces/IOpenApiExample.cs | 16 +++++++++ .../Models/OpenApiConstants.cs | 10 ++++++ .../Models/OpenApiExample.cs | 34 +++++++++++++++++++ .../References/OpenApiExampleReference.cs | 6 ++++ .../Reader/V3/OpenApiExampleDeserializer.cs | 2 ++ .../Reader/V31/OpenApiExampleDeserializer.cs | 2 ++ .../Reader/V32/OpenApiExampleDeserializer.cs | 12 +++++++ 7 files changed, 82 insertions(+) diff --git a/src/Microsoft.OpenApi/Models/Interfaces/IOpenApiExample.cs b/src/Microsoft.OpenApi/Models/Interfaces/IOpenApiExample.cs index bcb85c676..a26ff9b6e 100644 --- a/src/Microsoft.OpenApi/Models/Interfaces/IOpenApiExample.cs +++ b/src/Microsoft.OpenApi/Models/Interfaces/IOpenApiExample.cs @@ -22,4 +22,20 @@ public interface IOpenApiExample : IOpenApiDescribedElement, IOpenApiSummarizedE /// The value field and externalValue field are mutually exclusive. /// public string? ExternalValue { get; } + + /// + /// Embedded literal example value. + /// The dataValue property and the value property are mutually exclusive. + /// To represent examples of media types that cannot be naturally represented in JSON or YAML, + /// use a string value to contain the example with escaping where necessary. + /// Available in OpenAPI 3.2+, serialized as extension in 3.1 and earlier. + /// + public JsonNode? DataValue { get; } + + /// + /// A string representation of the example. + /// This is mutually exclusive with the value and dataValue properties. + /// Available in OpenAPI 3.2+, serialized as extension in 3.1 and earlier. + /// + public string? SerializedValue { get; } } diff --git a/src/Microsoft.OpenApi/Models/OpenApiConstants.cs b/src/Microsoft.OpenApi/Models/OpenApiConstants.cs index bb5f4f6d7..faebef5b0 100644 --- a/src/Microsoft.OpenApi/Models/OpenApiConstants.cs +++ b/src/Microsoft.OpenApi/Models/OpenApiConstants.cs @@ -340,6 +340,16 @@ public static class OpenApiConstants /// public const string ExternalValue = "externalValue"; + /// + /// Field: DataValue + /// + public const string DataValue = "dataValue"; + + /// + /// Field: SerializedValue + /// + public const string SerializedValue = "serializedValue"; + /// /// Field: DollarRef /// diff --git a/src/Microsoft.OpenApi/Models/OpenApiExample.cs b/src/Microsoft.OpenApi/Models/OpenApiExample.cs index 6c0352664..b3c93a5c7 100644 --- a/src/Microsoft.OpenApi/Models/OpenApiExample.cs +++ b/src/Microsoft.OpenApi/Models/OpenApiExample.cs @@ -23,6 +23,12 @@ public class OpenApiExample : IOpenApiExtensible, IOpenApiExample /// public JsonNode? Value { get; set; } + /// + public JsonNode? DataValue { get; set; } + + /// + public string? SerializedValue { get; set; } + /// public IDictionary? Extensions { get; set; } @@ -42,6 +48,8 @@ internal OpenApiExample(IOpenApiExample example) Description = example.Description ?? Description; Value = example.Value != null ? JsonNodeCloneHelper.Clone(example.Value) : null; ExternalValue = example.ExternalValue ?? ExternalValue; + DataValue = example.DataValue != null ? JsonNodeCloneHelper.Clone(example.DataValue) : null; + SerializedValue = example.SerializedValue ?? SerializedValue; Extensions = example.Extensions != null ? new Dictionary(example.Extensions) : null; } @@ -84,6 +92,32 @@ private void SerializeInternal(IOpenApiWriter writer, OpenApiSpecVersion version // externalValue writer.WriteProperty(OpenApiConstants.ExternalValue, ExternalValue); + // dataValue - serialize as native field in v3.2+, as extension in earlier versions + if (DataValue is not null) + { + if (version >= OpenApiSpecVersion.OpenApi3_2) + { + writer.WriteRequiredObject(OpenApiConstants.DataValue, DataValue, (w, v) => w.WriteAny(v)); + } + else + { + writer.WriteRequiredObject(OpenApiConstants.ExtensionFieldNamePrefix + "oai-" + OpenApiConstants.DataValue, DataValue, (w, v) => w.WriteAny(v)); + } + } + + // serializedValue - serialize as native field in v3.2+, as extension in earlier versions + if (SerializedValue is not null) + { + if (version >= OpenApiSpecVersion.OpenApi3_2) + { + writer.WriteProperty(OpenApiConstants.SerializedValue, SerializedValue); + } + else + { + writer.WriteProperty(OpenApiConstants.ExtensionFieldNamePrefix + "oai-" + OpenApiConstants.SerializedValue, SerializedValue); + } + } + // extensions writer.WriteExtensions(Extensions, version); diff --git a/src/Microsoft.OpenApi/Models/References/OpenApiExampleReference.cs b/src/Microsoft.OpenApi/Models/References/OpenApiExampleReference.cs index a616975bf..5834d4fb9 100644 --- a/src/Microsoft.OpenApi/Models/References/OpenApiExampleReference.cs +++ b/src/Microsoft.OpenApi/Models/References/OpenApiExampleReference.cs @@ -55,6 +55,12 @@ public string? Summary /// public JsonNode? Value { get => Target?.Value; } + /// + public JsonNode? DataValue { get => Target?.DataValue; } + + /// + public string? SerializedValue { get => Target?.SerializedValue; } + /// public override IOpenApiExample CopyReferenceAsTargetElementWithOverrides(IOpenApiExample source) { diff --git a/src/Microsoft.OpenApi/Reader/V3/OpenApiExampleDeserializer.cs b/src/Microsoft.OpenApi/Reader/V3/OpenApiExampleDeserializer.cs index fb3a44281..d429098dd 100644 --- a/src/Microsoft.OpenApi/Reader/V3/OpenApiExampleDeserializer.cs +++ b/src/Microsoft.OpenApi/Reader/V3/OpenApiExampleDeserializer.cs @@ -34,6 +34,8 @@ internal static partial class OpenApiV3Deserializer private static readonly PatternFieldMap _examplePatternFields = new() { + {s => s.Equals("x-oai-dataValue", StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.DataValue = n.CreateAny()}, + {s => s.Equals("x-oai-serializedValue", StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.SerializedValue = n.GetScalarValue()}, {s => s.StartsWith(OpenApiConstants.ExtensionFieldNamePrefix, StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.AddExtension(p, LoadExtension(p,n))} }; diff --git a/src/Microsoft.OpenApi/Reader/V31/OpenApiExampleDeserializer.cs b/src/Microsoft.OpenApi/Reader/V31/OpenApiExampleDeserializer.cs index 2bd891172..f9c0acbad 100644 --- a/src/Microsoft.OpenApi/Reader/V31/OpenApiExampleDeserializer.cs +++ b/src/Microsoft.OpenApi/Reader/V31/OpenApiExampleDeserializer.cs @@ -40,6 +40,8 @@ internal static partial class OpenApiV31Deserializer private static readonly PatternFieldMap _examplePatternFields = new() { + {s => s.Equals("x-oai-dataValue", StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.DataValue = n.CreateAny()}, + {s => s.Equals("x-oai-serializedValue", StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.SerializedValue = n.GetScalarValue()}, {s => s.StartsWith(OpenApiConstants.ExtensionFieldNamePrefix, StringComparison.OrdinalIgnoreCase), (o, p, n, _) => o.AddExtension(p, LoadExtension(p,n))} }; diff --git a/src/Microsoft.OpenApi/Reader/V32/OpenApiExampleDeserializer.cs b/src/Microsoft.OpenApi/Reader/V32/OpenApiExampleDeserializer.cs index b5287f982..81a89af56 100644 --- a/src/Microsoft.OpenApi/Reader/V32/OpenApiExampleDeserializer.cs +++ b/src/Microsoft.OpenApi/Reader/V32/OpenApiExampleDeserializer.cs @@ -34,6 +34,18 @@ internal static partial class OpenApiV32Deserializer o.ExternalValue = n.GetScalarValue(); } }, + { + "dataValue", (o, n, _) => + { + o.DataValue = n.CreateAny(); + } + }, + { + "serializedValue", (o, n, _) => + { + o.SerializedValue = n.GetScalarValue(); + } + }, }; From c39da76f5c669855066db22eea68c2253743f44e Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 1 Oct 2025 01:41:20 +0000 Subject: [PATCH 3/6] Add serialization and deserialization tests for new OpenApiExample fields Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --- .../V31Tests/OpenApiExampleTests.cs | 52 ++++++++++ .../OpenApiExample/exampleWithDataValue.yaml | 4 + .../exampleWithSerializedValue.yaml | 2 + .../V32Tests/OpenApiExampleTests.cs | 52 ++++++++++ .../OpenApiExample/exampleWithDataValue.yaml | 4 + .../exampleWithSerializedValue.yaml | 2 + ...sync_produceTerseOutput=False.verified.txt | 7 ++ ...Async_produceTerseOutput=True.verified.txt | 1 + ...sync_produceTerseOutput=False.verified.txt | 7 ++ ...Async_produceTerseOutput=True.verified.txt | 1 + ...sync_produceTerseOutput=False.verified.txt | 4 + ...Async_produceTerseOutput=True.verified.txt | 1 + ...sync_produceTerseOutput=False.verified.txt | 4 + ...Async_produceTerseOutput=True.verified.txt | 1 + .../Models/OpenApiExampleTests.cs | 96 +++++++++++++++++++ 15 files changed, 238 insertions(+) create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithDataValue.yaml create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithDataValue.yaml create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt create mode 100644 test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt diff --git a/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs new file mode 100644 index 000000000..bd953b80f --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT license. + +using System.IO; +using System.Text.Json.Nodes; +using System.Threading.Tasks; +using FluentAssertions; +using Microsoft.OpenApi.Reader; +using Xunit; + +namespace Microsoft.OpenApi.Readers.Tests.V31Tests +{ + [Collection("DefaultSettings")] + public class OpenApiExampleTests + { + private const string SampleFolderPath = "V31Tests/Samples/OpenApiExample/"; + + [Fact] + public async Task ParseExampleWithDataValueExtensionShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithDataValue.yaml"), + OpenApiSpecVersion.OpenApi3_1, + new(), + SettingsFixture.ReaderSettings); + + // Assert + example.Should().NotBeNull(); + example.Summary.Should().Be("Example with dataValue (extension)"); + example.DataValue.Should().NotBeNull(); + example.DataValue["name"].GetValue().Should().Be("Jane Smith"); + example.DataValue["age"].GetValue().Should().Be(25); + } + + [Fact] + public async Task ParseExampleWithSerializedValueExtensionShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithSerializedValue.yaml"), + OpenApiSpecVersion.OpenApi3_1, + new(), + SettingsFixture.ReaderSettings); + + // Assert + example.Should().NotBeNull(); + example.Summary.Should().Be("Example with serializedValue (extension)"); + example.SerializedValue.Should().Be("custom serialized string with extension"); + } + } +} diff --git a/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithDataValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithDataValue.yaml new file mode 100644 index 000000000..e32b3d37c --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithDataValue.yaml @@ -0,0 +1,4 @@ +summary: Example with dataValue (extension) +x-oai-dataValue: + name: Jane Smith + age: 25 diff --git a/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml new file mode 100644 index 000000000..7b9e1411c --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml @@ -0,0 +1,2 @@ +summary: Example with serializedValue (extension) +x-oai-serializedValue: "custom serialized string with extension" diff --git a/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs new file mode 100644 index 000000000..8859f8c0a --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs @@ -0,0 +1,52 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT license. + +using System.IO; +using System.Text.Json.Nodes; +using System.Threading.Tasks; +using FluentAssertions; +using Microsoft.OpenApi.Reader; +using Xunit; + +namespace Microsoft.OpenApi.Readers.Tests.V32Tests +{ + [Collection("DefaultSettings")] + public class OpenApiExampleTests + { + private const string SampleFolderPath = "V32Tests/Samples/OpenApiExample/"; + + [Fact] + public async Task ParseExampleWithDataValueShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithDataValue.yaml"), + OpenApiSpecVersion.OpenApi3_2, + new(), + SettingsFixture.ReaderSettings); + + // Assert + example.Should().NotBeNull(); + example.Summary.Should().Be("Example with dataValue"); + example.DataValue.Should().NotBeNull(); + example.DataValue["name"].GetValue().Should().Be("John Doe"); + example.DataValue["age"].GetValue().Should().Be(30); + } + + [Fact] + public async Task ParseExampleWithSerializedValueShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithSerializedValue.yaml"), + OpenApiSpecVersion.OpenApi3_2, + new(), + SettingsFixture.ReaderSettings); + + // Assert + example.Should().NotBeNull(); + example.Summary.Should().Be("Example with serializedValue"); + example.SerializedValue.Should().Be("custom serialized string"); + } + } +} diff --git a/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithDataValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithDataValue.yaml new file mode 100644 index 000000000..7c0a99061 --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithDataValue.yaml @@ -0,0 +1,4 @@ +summary: Example with dataValue +dataValue: + name: John Doe + age: 30 diff --git a/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml new file mode 100644 index 000000000..7644719e2 --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml @@ -0,0 +1,2 @@ +summary: Example with serializedValue +serializedValue: "custom serialized string" diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt new file mode 100644 index 000000000..8daafe6c0 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt @@ -0,0 +1,7 @@ +{ + "summary": "Example with dataValue", + "x-oai-dataValue": { + "name": "John Doe", + "age": 30 + } +} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt new file mode 100644 index 000000000..abfde16a5 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt @@ -0,0 +1 @@ +{"summary":"Example with dataValue","x-oai-dataValue":{"name":"John Doe","age":30}} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt new file mode 100644 index 000000000..1d95232a8 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt @@ -0,0 +1,7 @@ +{ + "summary": "Example with dataValue", + "dataValue": { + "name": "John Doe", + "age": 30 + } +} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt new file mode 100644 index 000000000..90d1b2069 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithDataValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt @@ -0,0 +1 @@ +{"summary":"Example with dataValue","dataValue":{"name":"John Doe","age":30}} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt new file mode 100644 index 000000000..5b08db9e8 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=False.verified.txt @@ -0,0 +1,4 @@ +{ + "summary": "Example with serializedValue", + "x-oai-serializedValue": "custom serialized string" +} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt new file mode 100644 index 000000000..166946f91 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV31JsonWorksAsync_produceTerseOutput=True.verified.txt @@ -0,0 +1 @@ +{"summary":"Example with serializedValue","x-oai-serializedValue":"custom serialized string"} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt new file mode 100644 index 000000000..5bcf0e6c7 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=False.verified.txt @@ -0,0 +1,4 @@ +{ + "summary": "Example with serializedValue", + "serializedValue": "custom serialized string" +} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt new file mode 100644 index 000000000..471eb2669 --- /dev/null +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.SerializeExampleWithSerializedValueAsV32JsonWorksAsync_produceTerseOutput=True.verified.txt @@ -0,0 +1 @@ +{"summary":"Example with serializedValue","serializedValue":"custom serialized string"} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.cs index 3fb95d8c7..e9f5e3d62 100644 --- a/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.cs +++ b/test/Microsoft.OpenApi.Tests/Models/OpenApiExampleTests.cs @@ -143,5 +143,101 @@ public async Task SerializeReferencedExampleAsV3JsonWithoutReferenceWorksAsync(b // Assert await Verifier.Verify(outputStringWriter).UseParameters(produceTerseOutput); } + + [Theory] + [InlineData(true)] + [InlineData(false)] + public async Task SerializeExampleWithDataValueAsV32JsonWorksAsync(bool produceTerseOutput) + { + // Arrange + var example = new OpenApiExample + { + Summary = "Example with dataValue", + DataValue = new JsonObject + { + ["name"] = "John Doe", + ["age"] = 30 + } + }; + var outputStringWriter = new StringWriter(CultureInfo.InvariantCulture); + var writer = new OpenApiJsonWriter(outputStringWriter, new() { Terse = produceTerseOutput }); + + // Act + example.SerializeAsV32(writer); + await writer.FlushAsync(); + + // Assert + await Verifier.Verify(outputStringWriter).UseParameters(produceTerseOutput); + } + + [Theory] + [InlineData(true)] + [InlineData(false)] + public async Task SerializeExampleWithDataValueAsV31JsonWorksAsync(bool produceTerseOutput) + { + // Arrange + var example = new OpenApiExample + { + Summary = "Example with dataValue", + DataValue = new JsonObject + { + ["name"] = "John Doe", + ["age"] = 30 + } + }; + var outputStringWriter = new StringWriter(CultureInfo.InvariantCulture); + var writer = new OpenApiJsonWriter(outputStringWriter, new() { Terse = produceTerseOutput }); + + // Act + example.SerializeAsV31(writer); + await writer.FlushAsync(); + + // Assert + await Verifier.Verify(outputStringWriter).UseParameters(produceTerseOutput); + } + + [Theory] + [InlineData(true)] + [InlineData(false)] + public async Task SerializeExampleWithSerializedValueAsV32JsonWorksAsync(bool produceTerseOutput) + { + // Arrange + var example = new OpenApiExample + { + Summary = "Example with serializedValue", + SerializedValue = "custom serialized string" + }; + var outputStringWriter = new StringWriter(CultureInfo.InvariantCulture); + var writer = new OpenApiJsonWriter(outputStringWriter, new() { Terse = produceTerseOutput }); + + // Act + example.SerializeAsV32(writer); + await writer.FlushAsync(); + + // Assert + await Verifier.Verify(outputStringWriter).UseParameters(produceTerseOutput); + } + + [Theory] + [InlineData(true)] + [InlineData(false)] + public async Task SerializeExampleWithSerializedValueAsV31JsonWorksAsync(bool produceTerseOutput) + { + // Arrange + var example = new OpenApiExample + { + Summary = "Example with serializedValue", + SerializedValue = "custom serialized string" + }; + var outputStringWriter = new StringWriter(CultureInfo.InvariantCulture); + var writer = new OpenApiJsonWriter(outputStringWriter, new() { Terse = produceTerseOutput }); + + // Act + example.SerializeAsV31(writer); + await writer.FlushAsync(); + + // Assert + await Verifier.Verify(outputStringWriter).UseParameters(produceTerseOutput); + } } } From 33a219e3c942ad0428511e6718282d518b067fb7 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 1 Oct 2025 01:44:38 +0000 Subject: [PATCH 4/6] Update public API export file for new OpenApiExample properties Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --- .../PublicApi/PublicApi.approved.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt b/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt index 43b2a35b7..8b7375001 100644 --- a/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt +++ b/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt @@ -116,7 +116,9 @@ namespace Microsoft.OpenApi public interface IOpenApiElement { } public interface IOpenApiExample : Microsoft.OpenApi.IOpenApiDescribedElement, Microsoft.OpenApi.IOpenApiElement, Microsoft.OpenApi.IOpenApiReadOnlyExtensible, Microsoft.OpenApi.IOpenApiReferenceable, Microsoft.OpenApi.IOpenApiSerializable, Microsoft.OpenApi.IOpenApiSummarizedElement, Microsoft.OpenApi.IShallowCopyable { + System.Text.Json.Nodes.JsonNode? DataValue { get; } string? ExternalValue { get; } + string? SerializedValue { get; } System.Text.Json.Nodes.JsonNode? Value { get; } } public interface IOpenApiExtensible : Microsoft.OpenApi.IOpenApiElement @@ -443,6 +445,7 @@ namespace Microsoft.OpenApi public const string Contact = "contact"; public const string Content = "content"; public const string ContentType = "contentType"; + public const string DataValue = "dataValue"; public const string Default = "default"; public const string DefaultDefault = "Default Default"; public const string DefaultDescription = "Default Description"; @@ -542,6 +545,7 @@ namespace Microsoft.OpenApi public const string SecurityDefinitions = "securityDefinitions"; public const string SecuritySchemes = "securitySchemes"; public const string Self = "$self"; + public const string SerializedValue = "serializedValue"; public const string Server = "server"; public const string Servers = "servers"; public const string Style = "style"; @@ -675,9 +679,11 @@ namespace Microsoft.OpenApi public class OpenApiExample : Microsoft.OpenApi.IOpenApiDescribedElement, Microsoft.OpenApi.IOpenApiElement, Microsoft.OpenApi.IOpenApiExample, Microsoft.OpenApi.IOpenApiExtensible, Microsoft.OpenApi.IOpenApiReadOnlyExtensible, Microsoft.OpenApi.IOpenApiReferenceable, Microsoft.OpenApi.IOpenApiSerializable, Microsoft.OpenApi.IOpenApiSummarizedElement, Microsoft.OpenApi.IShallowCopyable { public OpenApiExample() { } + public System.Text.Json.Nodes.JsonNode? DataValue { get; set; } public string? Description { get; set; } public System.Collections.Generic.IDictionary? Extensions { get; set; } public string? ExternalValue { get; set; } + public string? SerializedValue { get; set; } public string? Summary { get; set; } public System.Text.Json.Nodes.JsonNode? Value { get; set; } public Microsoft.OpenApi.IOpenApiExample CreateShallowCopy() { } @@ -689,9 +695,11 @@ namespace Microsoft.OpenApi public class OpenApiExampleReference : Microsoft.OpenApi.BaseOpenApiReferenceHolder, Microsoft.OpenApi.IOpenApiDescribedElement, Microsoft.OpenApi.IOpenApiElement, Microsoft.OpenApi.IOpenApiExample, Microsoft.OpenApi.IOpenApiReadOnlyExtensible, Microsoft.OpenApi.IOpenApiReferenceable, Microsoft.OpenApi.IOpenApiSerializable, Microsoft.OpenApi.IOpenApiSummarizedElement, Microsoft.OpenApi.IShallowCopyable { public OpenApiExampleReference(string referenceId, Microsoft.OpenApi.OpenApiDocument? hostDocument = null, string? externalResource = null) { } + public System.Text.Json.Nodes.JsonNode? DataValue { get; } public string? Description { get; set; } public System.Collections.Generic.IDictionary? Extensions { get; } public string? ExternalValue { get; } + public string? SerializedValue { get; } public string? Summary { get; set; } public System.Text.Json.Nodes.JsonNode? Value { get; } protected override Microsoft.OpenApi.OpenApiReferenceWithDescriptionAndSummary CopyReference(Microsoft.OpenApi.OpenApiReferenceWithDescriptionAndSummary sourceReference) { } From 688fcc5b2b0beea9e8c46c2c61a0b7828de72409 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 1 Oct 2025 12:43:36 +0000 Subject: [PATCH 5/6] Rewrite test assertions to use Assert methods instead of FluentAssertions and add V3 tests Co-authored-by: baywet <7905502+baywet@users.noreply.github.com> --- .../V31Tests/OpenApiExampleTests.cs | 17 +++++----- .../V32Tests/OpenApiExampleTests.cs | 17 +++++----- .../V3Tests/OpenApiExampleTests.cs | 34 +++++++++++++++++++ .../OpenApiExample/exampleWithDataValue.yaml | 4 +++ .../exampleWithSerializedValue.yaml | 2 ++ 5 files changed, 56 insertions(+), 18 deletions(-) create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithDataValue.yaml create mode 100644 test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml diff --git a/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs index bd953b80f..1f74aa4b3 100644 --- a/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs +++ b/test/Microsoft.OpenApi.Readers.Tests/V31Tests/OpenApiExampleTests.cs @@ -4,7 +4,6 @@ using System.IO; using System.Text.Json.Nodes; using System.Threading.Tasks; -using FluentAssertions; using Microsoft.OpenApi.Reader; using Xunit; @@ -26,11 +25,11 @@ public async Task ParseExampleWithDataValueExtensionShouldSucceed() SettingsFixture.ReaderSettings); // Assert - example.Should().NotBeNull(); - example.Summary.Should().Be("Example with dataValue (extension)"); - example.DataValue.Should().NotBeNull(); - example.DataValue["name"].GetValue().Should().Be("Jane Smith"); - example.DataValue["age"].GetValue().Should().Be(25); + Assert.NotNull(example); + Assert.Equal("Example with dataValue (extension)", example.Summary); + Assert.NotNull(example.DataValue); + Assert.Equal("Jane Smith", example.DataValue["name"].GetValue()); + Assert.Equal(25, example.DataValue["age"].GetValue()); } [Fact] @@ -44,9 +43,9 @@ public async Task ParseExampleWithSerializedValueExtensionShouldSucceed() SettingsFixture.ReaderSettings); // Assert - example.Should().NotBeNull(); - example.Summary.Should().Be("Example with serializedValue (extension)"); - example.SerializedValue.Should().Be("custom serialized string with extension"); + Assert.NotNull(example); + Assert.Equal("Example with serializedValue (extension)", example.Summary); + Assert.Equal("custom serialized string with extension", example.SerializedValue); } } } diff --git a/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs index 8859f8c0a..5d586f469 100644 --- a/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs +++ b/test/Microsoft.OpenApi.Readers.Tests/V32Tests/OpenApiExampleTests.cs @@ -4,7 +4,6 @@ using System.IO; using System.Text.Json.Nodes; using System.Threading.Tasks; -using FluentAssertions; using Microsoft.OpenApi.Reader; using Xunit; @@ -26,11 +25,11 @@ public async Task ParseExampleWithDataValueShouldSucceed() SettingsFixture.ReaderSettings); // Assert - example.Should().NotBeNull(); - example.Summary.Should().Be("Example with dataValue"); - example.DataValue.Should().NotBeNull(); - example.DataValue["name"].GetValue().Should().Be("John Doe"); - example.DataValue["age"].GetValue().Should().Be(30); + Assert.NotNull(example); + Assert.Equal("Example with dataValue", example.Summary); + Assert.NotNull(example.DataValue); + Assert.Equal("John Doe", example.DataValue["name"].GetValue()); + Assert.Equal(30, example.DataValue["age"].GetValue()); } [Fact] @@ -44,9 +43,9 @@ public async Task ParseExampleWithSerializedValueShouldSucceed() SettingsFixture.ReaderSettings); // Assert - example.Should().NotBeNull(); - example.Summary.Should().Be("Example with serializedValue"); - example.SerializedValue.Should().Be("custom serialized string"); + Assert.NotNull(example); + Assert.Equal("Example with serializedValue", example.Summary); + Assert.Equal("custom serialized string", example.SerializedValue); } } } diff --git a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiExampleTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiExampleTests.cs index ffd221d1a..e888b3d16 100644 --- a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiExampleTests.cs +++ b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiExampleTests.cs @@ -73,5 +73,39 @@ public async Task ParseExampleForcedStringSucceed() var result = await OpenApiDocument.LoadAsync(Path.Combine(SampleFolderPath, "explicitString.yaml"), SettingsFixture.ReaderSettings); Assert.Empty(result.Diagnostic.Errors); } + + [Fact] + public async Task ParseExampleWithDataValueExtensionShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithDataValue.yaml"), + OpenApiSpecVersion.OpenApi3_0, + new(), + SettingsFixture.ReaderSettings); + + // Assert + Assert.NotNull(example); + Assert.Equal("Example with dataValue (extension)", example.Summary); + Assert.NotNull(example.DataValue); + Assert.Equal("Alice Johnson", example.DataValue["name"].GetValue()); + Assert.Equal(28, example.DataValue["age"].GetValue()); + } + + [Fact] + public async Task ParseExampleWithSerializedValueExtensionShouldSucceed() + { + // Arrange & Act + var example = await OpenApiModelFactory.LoadAsync( + Path.Combine(SampleFolderPath, "exampleWithSerializedValue.yaml"), + OpenApiSpecVersion.OpenApi3_0, + new(), + SettingsFixture.ReaderSettings); + + // Assert + Assert.NotNull(example); + Assert.Equal("Example with serializedValue (extension)", example.Summary); + Assert.Equal("custom serialized string for V3", example.SerializedValue); + } } } diff --git a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithDataValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithDataValue.yaml new file mode 100644 index 000000000..5520aaea6 --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithDataValue.yaml @@ -0,0 +1,4 @@ +summary: Example with dataValue (extension) +x-oai-dataValue: + name: Alice Johnson + age: 28 diff --git a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml new file mode 100644 index 000000000..15ef28ee4 --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiExample/exampleWithSerializedValue.yaml @@ -0,0 +1,2 @@ +summary: Example with serializedValue (extension) +x-oai-serializedValue: "custom serialized string for V3" From ccef12b735acfc107167beafd3115f6992a4e0cc Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 1 Oct 2025 09:44:05 -0400 Subject: [PATCH 6/6] chore: updates benchmark results --- .../performance.Descriptions-report-github.md | 12 ++-- .../performance.Descriptions-report.csv | 8 +-- .../performance.Descriptions-report.html | 12 ++-- .../performance.Descriptions-report.json | 2 +- .../performance.EmptyModels-report-github.md | 60 +++++++++---------- .../performance.EmptyModels-report.csv | 56 ++++++++--------- .../performance.EmptyModels-report.html | 58 +++++++++--------- .../performance.EmptyModels-report.json | 2 +- 8 files changed, 105 insertions(+), 105 deletions(-) diff --git a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report-github.md b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report-github.md index 92580f7a6..a3632cd0c 100644 --- a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report-github.md +++ b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report-github.md @@ -10,9 +10,9 @@ Job=ShortRun IterationCount=3 LaunchCount=1 WarmupCount=3 ``` -| Method | Mean | Error | StdDev | Gen0 | Gen1 | Gen2 | Allocated | -|------------- |-------------:|-------------:|-------------:|-----------:|-----------:|----------:|-------------:| -| PetStoreYaml | 439.2 μs | 322.1 μs | 17.65 μs | 62.5000 | 11.7188 | - | 387.38 KB | -| PetStoreJson | 197.7 μs | 181.5 μs | 9.95 μs | 40.0391 | 8.7891 | - | 249.52 KB | -| GHESYaml | 912,587.8 μs | 748,677.7 μs | 41,037.55 μs | 66000.0000 | 22000.0000 | 4000.0000 | 384511.62 KB | -| GHESJson | 476,268.8 μs | 199,447.2 μs | 10,932.38 μs | 40000.0000 | 16000.0000 | 3000.0000 | 245982.3 KB | +| Method | Mean | Error | StdDev | Gen0 | Gen1 | Gen2 | Allocated | +|------------- |---------------:|--------------:|-------------:|-----------:|-----------:|----------:|-------------:| +| PetStoreYaml | 452.0 μs | 488.11 μs | 26.76 μs | 62.5000 | 11.7188 | - | 387.38 KB | +| PetStoreJson | 199.6 μs | 83.24 μs | 4.56 μs | 40.0391 | 8.7891 | - | 249.52 KB | +| GHESYaml | 1,001,468.3 μs | 766,455.68 μs | 42,012.02 μs | 65000.0000 | 21000.0000 | 3000.0000 | 384523.34 KB | +| GHESJson | 505,102.8 μs | 143,429.27 μs | 7,861.84 μs | 40000.0000 | 16000.0000 | 3000.0000 | 245995.15 KB | diff --git a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.csv b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.csv index 77b5a12cf..4bebdcff3 100644 --- a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.csv +++ b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.csv @@ -1,5 +1,5 @@ Method,Job,AnalyzeLaunchVariance,EvaluateOverhead,MaxAbsoluteError,MaxRelativeError,MinInvokeCount,MinIterationTime,OutlierMode,Affinity,EnvironmentVariables,Jit,LargeAddressAware,Platform,PowerPlanMode,Runtime,AllowVeryLargeObjects,Concurrent,CpuGroups,Force,HeapAffinitizeMask,HeapCount,NoAffinitize,RetainVm,Server,Arguments,BuildConfiguration,Clock,EngineFactory,NuGetReferences,Toolchain,IsMutator,InvocationCount,IterationCount,IterationTime,LaunchCount,MaxIterationCount,MaxWarmupIterationCount,MemoryRandomization,MinIterationCount,MinWarmupIterationCount,RunStrategy,UnrollFactor,WarmupCount,Mean,Error,StdDev,Gen0,Gen1,Gen2,Allocated -PetStoreYaml,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,439.2 μs,322.1 μs,17.65 μs,62.5000,11.7188,0.0000,387.38 KB -PetStoreJson,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,197.7 μs,181.5 μs,9.95 μs,40.0391,8.7891,0.0000,249.52 KB -GHESYaml,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,"912,587.8 μs","748,677.7 μs","41,037.55 μs",66000.0000,22000.0000,4000.0000,384511.62 KB -GHESJson,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,"476,268.8 μs","199,447.2 μs","10,932.38 μs",40000.0000,16000.0000,3000.0000,245982.3 KB +PetStoreYaml,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,452.0 μs,488.11 μs,26.76 μs,62.5000,11.7188,0.0000,387.38 KB +PetStoreJson,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,199.6 μs,83.24 μs,4.56 μs,40.0391,8.7891,0.0000,249.52 KB +GHESYaml,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,"1,001,468.3 μs","766,455.68 μs","42,012.02 μs",65000.0000,21000.0000,3000.0000,384523.34 KB +GHESJson,ShortRun,False,Default,Default,Default,Default,Default,Default,11111111,Empty,RyuJit,Default,X64,8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c,.NET 8.0,False,True,False,True,Default,Default,False,False,False,Default,Default,Default,Default,Default,Default,Default,Default,3,Default,1,Default,Default,Default,Default,Default,Default,16,3,"505,102.8 μs","143,429.27 μs","7,861.84 μs",40000.0000,16000.0000,3000.0000,245995.15 KB diff --git a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.html b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.html index b887f40f0..935d27afa 100644 --- a/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.html +++ b/performance/benchmark/BenchmarkDotNet.Artifacts/results/performance.Descriptions-report.html @@ -2,7 +2,7 @@ -performance.Descriptions-20251001-082523 +performance.Descriptions-20251001-093604