diff --git a/.azure-pipelines/ci-build.yml b/.azure-pipelines/ci-build.yml index 2f1b6b9b5..4ce92b8e9 100644 --- a/.azure-pipelines/ci-build.yml +++ b/.azure-pipelines/ci-build.yml @@ -31,9 +31,14 @@ stages: - job: build steps: - task: UseDotNet@2 - displayName: 'Use .NET 6' + displayName: 'Use .NET 2' # needed for ESRP signing inputs: - version: 6.x + version: 2.x + + - task: UseDotNet@2 + displayName: 'Use .NET 7' + inputs: + version: 7.x - task: PoliCheck@1 displayName: 'Run PoliCheck "/src"' diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index b972c9848..097fc3b96 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -16,7 +16,7 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v3 with: - dotnet-version: 6.0.x + dotnet-version: 7.0.x - name: Data gatherer id: data_gatherer @@ -49,7 +49,7 @@ jobs: - if: steps.conditionals_handler.outputs.is_default_branch == 'true' name: Bump GH tag id: tag_generator - uses: mathieudutour/github-tag-action@v6.0 + uses: mathieudutour/github-tag-action@v6.1 with: github_token: ${{ secrets.GITHUB_TOKEN }} default_bump: false diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index eb56ea14f..89d7e62c1 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -19,7 +19,7 @@ jobs: - name: Setup .NET uses: actions/setup-dotnet@v3 with: - dotnet-version: 6.0.x + dotnet-version: 7.0.x - name: Initialize CodeQL id: init_codeql diff --git a/.vscode/launch.json b/.vscode/launch.json index b59349979..974002cfe 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -10,7 +10,7 @@ "request": "launch", "preLaunchTask": "build", // If you have changed target frameworks, make sure to update the program path. - "program": "${workspaceFolder}/src/Microsoft.OpenApi.Hidi/bin/Debug/net6.0/Microsoft.OpenApi.Hidi.dll", + "program": "${workspaceFolder}/src/Microsoft.OpenApi.Hidi/bin/Debug/net7.0/Microsoft.OpenApi.Hidi.dll", "args": [], "cwd": "${workspaceFolder}/src/Microsoft.OpenApi.Hidi", // For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console diff --git a/Dockerfile b/Dockerfile index 8326ce3b9..6b3507124 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,14 @@ -FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build-env +FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build-env WORKDIR /app COPY ./src ./hidi/src WORKDIR /app/hidi RUN dotnet publish ./src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj -c Release -FROM mcr.microsoft.com/dotnet/runtime:6.0 as runtime +FROM mcr.microsoft.com/dotnet/runtime:7.0 as runtime WORKDIR /app -COPY --from=build-env /app/hidi/src/Microsoft.OpenApi.Hidi/bin/Release/net6.0 ./ +COPY --from=build-env /app/hidi/src/Microsoft.OpenApi.Hidi/bin/Release/net7.0 ./ VOLUME /app/output VOLUME /app/openapi.yml diff --git a/src/Microsoft.OpenApi.Hidi/Handlers/TransformCommandHandler.cs b/src/Microsoft.OpenApi.Hidi/Handlers/TransformCommandHandler.cs index e8d9431de..696837d3f 100644 --- a/src/Microsoft.OpenApi.Hidi/Handlers/TransformCommandHandler.cs +++ b/src/Microsoft.OpenApi.Hidi/Handlers/TransformCommandHandler.cs @@ -21,6 +21,7 @@ internal class TransformCommandHandler : ICommandHandler public Option VersionOption { get; set; } public Option FormatOption { get; set; } public Option TerseOutputOption { get; set; } + public Option SettingsFileOption { get; set; } public Option LogLevelOption { get; set; } public Option FilterByOperationIdsOption { get; set; } public Option FilterByTagsOption { get; set; } @@ -42,6 +43,7 @@ public async Task InvokeAsync(InvocationContext context) string? version = context.ParseResult.GetValueForOption(VersionOption); OpenApiFormat? format = context.ParseResult.GetValueForOption(FormatOption); bool terseOutput = context.ParseResult.GetValueForOption(TerseOutputOption); + string settingsFile = context.ParseResult.GetValueForOption(SettingsFileOption); LogLevel logLevel = context.ParseResult.GetValueForOption(LogLevelOption); bool inlineLocal = context.ParseResult.GetValueForOption(InlineLocalOption); bool inlineExternal = context.ParseResult.GetValueForOption(InlineExternalOption); @@ -54,7 +56,7 @@ public async Task InvokeAsync(InvocationContext context) var logger = loggerFactory.CreateLogger(); try { - await OpenApiService.TransformOpenApiDocument(openapi, csdl, csdlFilter, output, cleanOutput, version, format, terseOutput, logLevel, inlineLocal, inlineExternal, filterbyoperationids, filterbytags, filterbycollection, cancellationToken); + await OpenApiService.TransformOpenApiDocument(openapi, csdl, csdlFilter, output, cleanOutput, version, format, terseOutput, settingsFile, logLevel, inlineLocal, inlineExternal, filterbyoperationids, filterbytags, filterbycollection, cancellationToken); return 0; } diff --git a/src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj b/src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj index c77e30194..aba953065 100644 --- a/src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj +++ b/src/Microsoft.OpenApi.Hidi/Microsoft.OpenApi.Hidi.csproj @@ -2,7 +2,7 @@ Exe - net6.0 + net7.0 9.0 true http://go.microsoft.com/fwlink/?LinkID=288890 @@ -15,7 +15,7 @@ Microsoft.OpenApi.Hidi hidi ./../../artifacts - 1.1.0-preview3 + 1.1.0 OpenAPI.NET CLI tool for slicing OpenAPI documents © Microsoft Corporation. All rights reserved. OpenAPI .NET @@ -37,13 +37,14 @@ - - - - + + + + - - + + + @@ -51,4 +52,12 @@ + + + + <_Parameter1>Microsoft.OpenApi.Hidi.Tests + + + + diff --git a/src/Microsoft.OpenApi.Hidi/OpenApiService.cs b/src/Microsoft.OpenApi.Hidi/OpenApiService.cs index 034350f1a..0d9500682 100644 --- a/src/Microsoft.OpenApi.Hidi/OpenApiService.cs +++ b/src/Microsoft.OpenApi.Hidi/OpenApiService.cs @@ -27,6 +27,8 @@ using System.Xml.Xsl; using System.Xml; using System.Reflection; +using Microsoft.Extensions.Configuration; +using System.Runtime.CompilerServices; namespace Microsoft.OpenApi.Hidi { @@ -44,6 +46,7 @@ public static async Task TransformOpenApiDocument( string? version, OpenApiFormat? format, bool terseOutput, + string settingsFile, LogLevel logLevel, bool inlineLocal, bool inlineExternal, @@ -98,7 +101,8 @@ CancellationToken cancellationToken stream = ApplyFilter(csdl, csdlFilter, transform); stream.Position = 0; } - document = await ConvertCsdlToOpenApi(stream); + + document = await ConvertCsdlToOpenApi(stream, settingsFile); stopwatch.Stop(); logger.LogTrace("{timestamp}ms: Generated OpenAPI with {paths} paths.", stopwatch.ElapsedMilliseconds, document.Paths.Count); } @@ -304,17 +308,29 @@ public static async Task ValidateOpenApiDocument( } } + internal static IConfiguration GetConfiguration(string settingsFile) + { + settingsFile ??= "appsettings.json"; + + IConfiguration config = new ConfigurationBuilder() + .AddJsonFile(settingsFile, true) + .Build(); + + return config; + } + /// /// Converts CSDL to OpenAPI /// /// The CSDL stream. /// An OpenAPI document. - public static async Task ConvertCsdlToOpenApi(Stream csdl) + public static async Task ConvertCsdlToOpenApi(Stream csdl, string settingsFile = null) { using var reader = new StreamReader(csdl); var csdlText = await reader.ReadToEndAsync(); var edmModel = CsdlReader.Parse(XElement.Parse(csdlText).CreateReader()); - + + var config = GetConfiguration(settingsFile); var settings = new OpenApiConvertSettings() { AddSingleQuotesForStringParameters = true, @@ -322,7 +338,7 @@ public static async Task ConvertCsdlToOpenApi(Stream csdl) DeclarePathParametersOnPathItem = true, EnableKeyAsSegment = true, EnableOperationId = true, - ErrorResponsesAsDefault = false, + ErrorResponsesAsDefault = false, PrefixEntityTypeNameBeforeKey = true, TagDepth = 2, EnablePagination = true, @@ -335,6 +351,8 @@ public static async Task ConvertCsdlToOpenApi(Stream csdl) EnableCount = true, UseSuccessStatusCodeRange = true }; + config.GetSection("OpenApiConvertSettings").Bind(settings); + OpenApiDocument document = edmModel.ConvertToOpenApi(settings); document = FixReferences(document); diff --git a/src/Microsoft.OpenApi.Hidi/Program.cs b/src/Microsoft.OpenApi.Hidi/Program.cs index 926c58deb..71e9e0d00 100644 --- a/src/Microsoft.OpenApi.Hidi/Program.cs +++ b/src/Microsoft.OpenApi.Hidi/Program.cs @@ -2,8 +2,14 @@ // Licensed under the MIT license. using System.CommandLine; +using System.CommandLine.Builder; +using System.CommandLine.Hosting; +using System.CommandLine.Parsing; + using System.IO; using System.Threading.Tasks; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Hosting; using Microsoft.Extensions.Logging; using Microsoft.OpenApi.Hidi.Handlers; @@ -41,6 +47,9 @@ static async Task Main(string[] args) var terseOutputOption = new Option("--terse-output", "Produce terse json output"); terseOutputOption.AddAlias("--to"); + var settingsFileOption = new Option("--settings-path", "The configuration file with CSDL conversion settings."); + settingsFileOption.AddAlias("--sp"); + var logLevelOption = new Option("--log-level", () => LogLevel.Information, "The log level to use when logging messages to the main output."); logLevelOption.AddAlias("--ll"); @@ -81,6 +90,7 @@ static async Task Main(string[] args) versionOption, formatOption, terseOutputOption, + settingsFileOption, logLevelOption, filterByOperationIdsOption, filterByTagsOption, @@ -99,6 +109,7 @@ static async Task Main(string[] args) VersionOption = versionOption, FormatOption = formatOption, TerseOutputOption = terseOutputOption, + SettingsFileOption = settingsFileOption, LogLevelOption = logLevelOption, FilterByOperationIdsOption = filterByOperationIdsOption, FilterByTagsOption = filterByTagsOption, diff --git a/src/Microsoft.OpenApi.Readers/Microsoft.OpenApi.Readers.csproj b/src/Microsoft.OpenApi.Readers/Microsoft.OpenApi.Readers.csproj index d21c300eb..defdfdd54 100644 --- a/src/Microsoft.OpenApi.Readers/Microsoft.OpenApi.Readers.csproj +++ b/src/Microsoft.OpenApi.Readers/Microsoft.OpenApi.Readers.csproj @@ -10,7 +10,7 @@ Microsoft Microsoft.OpenApi.Readers Microsoft.OpenApi.Readers - 1.4.4-preview1 + 1.4.4 OpenAPI.NET Readers for JSON and YAML documents © Microsoft Corporation. All rights reserved. OpenAPI .NET diff --git a/src/Microsoft.OpenApi.Readers/V3/OpenApiV3VersionService.cs b/src/Microsoft.OpenApi.Readers/V3/OpenApiV3VersionService.cs index 40b40e85a..ebe372d40 100644 --- a/src/Microsoft.OpenApi.Readers/V3/OpenApiV3VersionService.cs +++ b/src/Microsoft.OpenApi.Readers/V3/OpenApiV3VersionService.cs @@ -105,11 +105,12 @@ public OpenApiReference ConvertToOpenApiReference( catch (OpenApiException ex) { Diagnostic.Errors.Add(new OpenApiError(ex)); - return null; } } // Where fragments point into a non-OpenAPI document, the id will be the complete fragment identifier string id = segments[1]; + var openApiReference = new OpenApiReference(); + // $ref: externalSource.yaml#/Pet if (id.StartsWith("/components/")) { @@ -128,13 +129,16 @@ public OpenApiReference ConvertToOpenApiReference( } id = localSegments[3]; } - - return new OpenApiReference + else { - ExternalResource = segments[0], - Type = type, - Id = id - }; + openApiReference.IsFragrament = true; + } + + openApiReference.ExternalResource = segments[0]; + openApiReference.Type = type; + openApiReference.Id = id; + + return openApiReference; } } diff --git a/src/Microsoft.OpenApi.Workbench/Microsoft.OpenApi.Workbench.csproj b/src/Microsoft.OpenApi.Workbench/Microsoft.OpenApi.Workbench.csproj index a47b5af48..ad6989d05 100644 --- a/src/Microsoft.OpenApi.Workbench/Microsoft.OpenApi.Workbench.csproj +++ b/src/Microsoft.OpenApi.Workbench/Microsoft.OpenApi.Workbench.csproj @@ -1,16 +1,16 @@  - net6.0-windows + net7.0-windows WinExe false true true - + all - + diff --git a/src/Microsoft.OpenApi/Microsoft.OpenApi.csproj b/src/Microsoft.OpenApi/Microsoft.OpenApi.csproj index 1affa74c6..50d026f91 100644 --- a/src/Microsoft.OpenApi/Microsoft.OpenApi.csproj +++ b/src/Microsoft.OpenApi/Microsoft.OpenApi.csproj @@ -11,7 +11,7 @@ Microsoft Microsoft.OpenApi Microsoft.OpenApi - 1.4.4-preview1 + 1.4.4 .NET models with JSON and YAML writers for OpenAPI specification © Microsoft Corporation. All rights reserved. OpenAPI .NET diff --git a/src/Microsoft.OpenApi/Models/OpenApiReference.cs b/src/Microsoft.OpenApi/Models/OpenApiReference.cs index ecc643dc3..e8798cc64 100644 --- a/src/Microsoft.OpenApi/Models/OpenApiReference.cs +++ b/src/Microsoft.OpenApi/Models/OpenApiReference.cs @@ -45,6 +45,11 @@ public class OpenApiReference : IOpenApiSerializable /// public bool IsLocal => ExternalResource == null; + /// + /// Gets a flag indicating whether a file is a valid OpenAPI document or a fragment + /// + public bool IsFragrament = false; + /// /// The OpenApiDocument that is hosting the OpenApiReference instance. This is used to enable dereferencing the reference. /// @@ -196,7 +201,12 @@ private string GetExternalReferenceV3() { if (Id != null) { - return ExternalResource + "#/components/" + Type.GetDisplayName() + "/"+ Id; + if (IsFragrament) + { + return ExternalResource + "#" + Id; + } + + return ExternalResource + "#/components/" + Type.GetDisplayName() + "/"+ Id; } return ExternalResource; diff --git a/test/Microsoft.OpenApi.Hidi.Tests/Microsoft.OpenApi.Hidi.Tests.csproj b/test/Microsoft.OpenApi.Hidi.Tests/Microsoft.OpenApi.Hidi.Tests.csproj index 1a4002daa..f450e2ff7 100644 --- a/test/Microsoft.OpenApi.Hidi.Tests/Microsoft.OpenApi.Hidi.Tests.csproj +++ b/test/Microsoft.OpenApi.Hidi.Tests/Microsoft.OpenApi.Hidi.Tests.csproj @@ -1,7 +1,7 @@ - net6.0 + net7.0 enable enable @@ -9,14 +9,14 @@ - + runtime; build; native; contentfiles; analyzers; buildtransitive all - + runtime; build; native; contentfiles; analyzers; buildtransitive all @@ -34,6 +34,9 @@ + + Always + Always diff --git a/test/Microsoft.OpenApi.Hidi.Tests/Services/OpenApiServiceTests.cs b/test/Microsoft.OpenApi.Hidi.Tests/Services/OpenApiServiceTests.cs index af5437aa1..c2fb3798f 100644 --- a/test/Microsoft.OpenApi.Hidi.Tests/Services/OpenApiServiceTests.cs +++ b/test/Microsoft.OpenApi.Hidi.Tests/Services/OpenApiServiceTests.cs @@ -1,10 +1,9 @@ // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT license. -using System; -using System.IO; -using System.Threading.Tasks; +using Microsoft.Extensions.Configuration; using Microsoft.OpenApi.Hidi; +using Microsoft.OpenApi.OData; using Microsoft.OpenApi.Services; using Xunit; @@ -51,5 +50,26 @@ public async Task ReturnFilteredOpenApiDocBasedOnOperationIdsAndInputCsdlDocumen Assert.NotEmpty(subsetOpenApiDocument.Paths); Assert.Equal(expectedPathCount, subsetOpenApiDocument.Paths.Count); } + + [Theory] + [InlineData("UtilityFiles/appsettingstest.json")] + [InlineData(null)] + public void ReturnOpenApiConvertSettingsWhenSettingsFileIsProvided(string filePath) + { + // Arrange + var config = OpenApiService.GetConfiguration(filePath); + + // Act and Assert + var settings = config.GetSection("OpenApiConvertSettings").Get(); + + if (filePath == null) + { + Assert.Null(settings); + } + else + { + Assert.NotNull(settings); + } + } } } diff --git a/test/Microsoft.OpenApi.Hidi.Tests/UtilityFiles/appsettingstest.json b/test/Microsoft.OpenApi.Hidi.Tests/UtilityFiles/appsettingstest.json new file mode 100644 index 000000000..a71d0a9fa --- /dev/null +++ b/test/Microsoft.OpenApi.Hidi.Tests/UtilityFiles/appsettingstest.json @@ -0,0 +1,21 @@ +{ + "OpenApiConvertSettings": { + "AddSingleQuotesForStringParameters": "true", + "AddEnumDescriptionExtension": "true", + "DeclarePathParametersOnPathItem": "true", + "EnableKeyAsSegment": "true", + "EnableOperationId": "true", + "ErrorResponsesAsDefault": "false", + "PrefixEntityTypeNameBeforeKey": "true", + "TagDepth": 2, + "EnablePagination": "true", + "EnableDiscriminatorValue": "true", + "EnableDerivedTypesReferencesForRequestBody": "false", + "EnableDerivedTypesReferencesForResponses": "false", + "ShowRootPath": "false", + "ShowLinks": "false", + "ExpandDerivedTypesNavigationProperties": "false", + "EnableCount": "true", + "UseSuccessStatusCodeRange": "true" + } +} \ No newline at end of file diff --git a/test/Microsoft.OpenApi.Readers.Tests/Microsoft.OpenApi.Readers.Tests.csproj b/test/Microsoft.OpenApi.Readers.Tests/Microsoft.OpenApi.Readers.Tests.csproj index 1c46de041..a12969f52 100644 --- a/test/Microsoft.OpenApi.Readers.Tests/Microsoft.OpenApi.Readers.Tests.csproj +++ b/test/Microsoft.OpenApi.Readers.Tests/Microsoft.OpenApi.Readers.Tests.csproj @@ -1,6 +1,6 @@ - net6.0 + net7.0 false Microsoft @@ -149,6 +149,9 @@ Never + + Never + Never @@ -250,10 +253,10 @@ - + - + diff --git a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiDocumentTests.cs b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiDocumentTests.cs index 6fbb7065a..362609291 100644 --- a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiDocumentTests.cs +++ b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/OpenApiDocumentTests.cs @@ -6,6 +6,7 @@ using System.Globalization; using System.IO; using System.Linq; +using System.Text; using System.Threading; using FluentAssertions; using Microsoft.OpenApi.Any; @@ -1327,5 +1328,24 @@ public void HeaderParameterShouldAllowExample() }); } } + + [Fact] + public void DoesNotChangeExternalReferences() + { + // Arrange + using var stream = Resources.GetStream(Path.Combine(SampleFolderPath, "documentWithExternalRefs.yaml")); + + // Act + var doc = new OpenApiStreamReader( + new OpenApiReaderSettings { ReferenceResolution = ReferenceResolutionSetting.DoNotResolveReferences}) + .Read(stream, out var diagnostic); + + var externalRef = doc.Components.Schemas["Nested"].Properties["AnyOf"].AnyOf.First().Reference.ReferenceV3; + var externalRef2 = doc.Components.Schemas["Nested"].Properties["AnyOf"].AnyOf.Last().Reference.ReferenceV3; + + // Assert + Assert.Equal("file:///C:/MySchemas.json#/definitions/ArrayObject", externalRef); + Assert.Equal("../foo/schemas.yaml#/components/schemas/Number", externalRef2); + } } } diff --git a/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiDocument/documentWithExternalRefs.yaml b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiDocument/documentWithExternalRefs.yaml new file mode 100644 index 000000000..c0b7b3a25 --- /dev/null +++ b/test/Microsoft.OpenApi.Readers.Tests/V3Tests/Samples/OpenApiDocument/documentWithExternalRefs.yaml @@ -0,0 +1,16 @@ + openapi: 3.0.1 + info: + title: anyOf-oneOf + license: + name: MIT + version: 1.0.0 + paths: { } + components: + schemas: + Nested: + type: object + properties: + AnyOf: + anyOf: + - $ref: file:///C:/MySchemas.json#/definitions/ArrayObject + - $ref: ../foo/schemas.yaml#/components/schemas/Number \ No newline at end of file diff --git a/test/Microsoft.OpenApi.SmokeTests/Microsoft.OpenApi.SmokeTests.csproj b/test/Microsoft.OpenApi.SmokeTests/Microsoft.OpenApi.SmokeTests.csproj index 7f41b101f..9c88e8394 100644 --- a/test/Microsoft.OpenApi.SmokeTests/Microsoft.OpenApi.SmokeTests.csproj +++ b/test/Microsoft.OpenApi.SmokeTests/Microsoft.OpenApi.SmokeTests.csproj @@ -1,15 +1,15 @@  - net6.0 + net7.0 - - + + all diff --git a/test/Microsoft.OpenApi.Tests/Microsoft.OpenApi.Tests.csproj b/test/Microsoft.OpenApi.Tests/Microsoft.OpenApi.Tests.csproj index d1f97f6f3..e2a21cc74 100644 --- a/test/Microsoft.OpenApi.Tests/Microsoft.OpenApi.Tests.csproj +++ b/test/Microsoft.OpenApi.Tests/Microsoft.OpenApi.Tests.csproj @@ -1,6 +1,6 @@  - net6.0 + net7.0 false Microsoft @@ -16,11 +16,11 @@ - + - + all diff --git a/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt b/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt index 75e12f480..b8646cae5 100755 --- a/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt +++ b/test/Microsoft.OpenApi.Tests/PublicApi/PublicApi.approved.txt @@ -1,7 +1,7 @@ [assembly: System.Reflection.AssemblyMetadata("RepositoryUrl", "https://github.com/Microsoft/OpenAPI.NET")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo(@"Microsoft.OpenApi.Readers.Tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100957cb48387b2a5f54f5ce39255f18f26d32a39990db27cf48737afc6bc62759ba996b8a2bfb675d4e39f3d06ecb55a178b1b4031dcb2a767e29977d88cce864a0d16bfc1b3bebb0edf9fe285f10fffc0a85f93d664fa05af07faa3aad2e545182dbf787e3fd32b56aca95df1a3c4e75dec164a3f1a4c653d971b01ffc39eb3c4")] [assembly: System.Runtime.CompilerServices.InternalsVisibleTo(@"Microsoft.OpenApi.Tests, PublicKey=0024000004800000940000000602000000240000525341310004000001000100957cb48387b2a5f54f5ce39255f18f26d32a39990db27cf48737afc6bc62759ba996b8a2bfb675d4e39f3d06ecb55a178b1b4031dcb2a767e29977d88cce864a0d16bfc1b3bebb0edf9fe285f10fffc0a85f93d664fa05af07faa3aad2e545182dbf787e3fd32b56aca95df1a3c4e75dec164a3f1a4c653d971b01ffc39eb3c4")] -[assembly: System.Runtime.Versioning.TargetFramework(".NETStandard,Version=v2.0", FrameworkDisplayName="")] +[assembly: System.Runtime.Versioning.TargetFramework(".NETStandard,Version=v2.0", FrameworkDisplayName=".NET Standard 2.0")] namespace Microsoft.OpenApi.Any { public enum AnyType @@ -773,6 +773,7 @@ namespace Microsoft.OpenApi.Models } public class OpenApiReference : Microsoft.OpenApi.Interfaces.IOpenApiElement, Microsoft.OpenApi.Interfaces.IOpenApiSerializable { + public bool IsFragrament; public OpenApiReference() { } public OpenApiReference(Microsoft.OpenApi.Models.OpenApiReference reference) { } public string ExternalResource { get; set; }