diff --git a/build/Build.CI.GitHubActions.cs b/build/Build.CI.GitHubActions.cs index 1dfa1f4195..df29af7924 100644 --- a/build/Build.CI.GitHubActions.cs +++ b/build/Build.CI.GitHubActions.cs @@ -45,7 +45,7 @@ protected override GitHubActionsJob GetJobs(GitHubActionsImage image, IReadOnlyC var job = base.GetJobs(image, relevantTargets); var newSteps = new List(job.Steps); - foreach (var version in new[] { "6.0.*", "5.0.*", "3.1.*", "2.1.*" }) + foreach (var version in new[] { "6.0.*", "3.1.*" }) { newSteps.Insert(1, new GitHubActionsSetupDotNetStep { diff --git a/build/Build.cs b/build/Build.cs index 69afb3d27c..ab5da07470 100644 --- a/build/Build.cs +++ b/build/Build.cs @@ -313,17 +313,16 @@ void NSwagRun( } } - /* TODO should upgrade sample to NET 6.0 var samplesPath = RootDirectory / "samples"; var sampleSolution = ProjectModelTasks.ParseSolution(samplesPath / "Samples.sln"); - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_assembly", "NetCore21", Configuration.Release, true); - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_project", "NetCore21", Configuration.Release, false); - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_reflection", "NetCore21", Configuration.Release, true); - - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_assembly", "NetCore21", Configuration.Debug, true); - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_project", "NetCore21", Configuration.Debug, false); - NSwagRun(sampleSolution.GetProject("Sample.AspNetCore21"), "nswag_reflection", "NetCore21", Configuration.Debug, true); - */ + var sampleProject = sampleSolution.GetProject(new Guid("55E2BF82-3ECE-45E2-96BD-65C09C42843D")); + NSwagRun(sampleProject, "nswag_assembly", "NetCore31", Configuration.Release, true); + NSwagRun(sampleProject, "nswag_project", "NetCore31", Configuration.Release, false); + NSwagRun(sampleProject, "nswag_reflection", "NetCore31", Configuration.Release, true); + + NSwagRun(sampleProject, "nswag_assembly", "NetCore31", Configuration.Debug, true); + NSwagRun(sampleProject, "nswag_project", "NetCore31", Configuration.Debug, false); + NSwagRun(sampleProject, "nswag_reflection", "NetCore31", Configuration.Debug, true); }); void PublishAndCopyConsoleProjects() diff --git a/samples/Samples.sln b/samples/Samples.sln index d5eedd5116..84b78a8b4f 100644 --- a/samples/Samples.sln +++ b/samples/Samples.sln @@ -3,9 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 16 VisualStudioVersion = 16.0.29613.14 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Sample.AspNetCore20", "WithoutMiddleware\Sample.AspNetCore20\Sample.AspNetCore20.csproj", "{5A204483-5A44-4B80-8B0B-A58284CC4CCB}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Sample.AspNetCore21", "WithoutMiddleware\Sample.AspNetCore21\Sample.AspNetCore21.csproj", "{55E2BF82-3ECE-45E2-96BD-65C09C42843D}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Sample.AspNetCore31", "WithoutMiddleware\Sample.AspNetCore31\Sample.AspNetCore31.csproj", "{55E2BF82-3ECE-45E2-96BD-65C09C42843D}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sample.NetOwinMiddleware", "WithMiddleware\Sample.NetOwinMiddleware\Sample.NetOwinMiddleware.csproj", "{F8839807-B6F6-41E3-BC98-DFAD3C03085E}" EndProject @@ -23,10 +21,6 @@ Global Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {5A204483-5A44-4B80-8B0B-A58284CC4CCB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {5A204483-5A44-4B80-8B0B-A58284CC4CCB}.Debug|Any CPU.Build.0 = Debug|Any CPU - {5A204483-5A44-4B80-8B0B-A58284CC4CCB}.Release|Any CPU.ActiveCfg = Release|Any CPU - {5A204483-5A44-4B80-8B0B-A58284CC4CCB}.Release|Any CPU.Build.0 = Release|Any CPU {55E2BF82-3ECE-45E2-96BD-65C09C42843D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {55E2BF82-3ECE-45E2-96BD-65C09C42843D}.Debug|Any CPU.Build.0 = Debug|Any CPU {55E2BF82-3ECE-45E2-96BD-65C09C42843D}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -48,7 +42,6 @@ Global HideSolutionNode = FALSE EndGlobalSection GlobalSection(NestedProjects) = preSolution - {5A204483-5A44-4B80-8B0B-A58284CC4CCB} = {BF07E900-C7DE-4ADA-8563-E09E6B5AACF0} {55E2BF82-3ECE-45E2-96BD-65C09C42843D} = {BF07E900-C7DE-4ADA-8563-E09E6B5AACF0} {F8839807-B6F6-41E3-BC98-DFAD3C03085E} = {29EDA9F6-189B-4F96-B5BE-B7B82EB8A62A} {2F6620B8-D19D-4710-AAB9-4E2B785F5FA5} = {29EDA9F6-189B-4F96-B5BE-B7B82EB8A62A} diff --git a/samples/WithMiddleware/Sample.AspNetCore31.Client/Clients.generated.cs b/samples/WithMiddleware/Sample.AspNetCore31.Client/Clients.generated.cs index 85a272eef8..df233d381b 100644 --- a/samples/WithMiddleware/Sample.AspNetCore31.Client/Clients.generated.cs +++ b/samples/WithMiddleware/Sample.AspNetCore31.Client/Clients.generated.cs @@ -1,6 +1,6 @@ //---------------------- // -// Generated using the NSwag toolchain v13.8.2.0 (NJsonSchema v10.2.1.0 (Newtonsoft.Json v12.0.0.0)) (http://NSwag.org) +// Generated using the NSwag toolchain v13.14.5.0 (NJsonSchema v10.5.2.0 (Newtonsoft.Json v12.0.0.0)) (http://NSwag.org) // //---------------------- @@ -9,12 +9,14 @@ #pragma warning disable 472 // Disable "CS0472 The result of the expression is always 'false' since a value of type 'Int32' is never equal to 'null' of type 'Int32?' #pragma warning disable 1573 // Disable "CS1573 Parameter '...' has no matching param tag in the XML comment for ... #pragma warning disable 1591 // Disable "CS1591 Missing XML comment for publicly visible type or member ..." +#pragma warning disable 8073 // Disable "CS8073 The result of the expression is always 'false' since a value of type 'T' is never equal to 'null' of type 'T?'" +#pragma warning disable 3016 // Disable "CS3016 Arrays as attribute arguments is not CLS-compliant" namespace Apimundo.Client { using System = global::System; - - [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.8.2.0 (NJsonSchema v10.2.1.0 (Newtonsoft.Json v12.0.0.0))")] + + [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.14.5.0 (NJsonSchema v10.5.2.0 (Newtonsoft.Json v12.0.0.0))")] public partial class WeatherForecastClient { private System.Net.Http.HttpClient _httpClient; @@ -22,7 +24,7 @@ public partial class WeatherForecastClient public WeatherForecastClient(System.Net.Http.HttpClient httpClient) { - _httpClient = httpClient; + _httpClient = httpClient; _settings = new System.Lazy(CreateSerializerSettings); } @@ -36,10 +38,11 @@ private Newtonsoft.Json.JsonSerializerSettings CreateSerializerSettings() protected Newtonsoft.Json.JsonSerializerSettings JsonSerializerSettings { get { return _settings.Value; } } partial void UpdateJsonSerializerSettings(Newtonsoft.Json.JsonSerializerSettings settings); + + partial void PrepareRequest(System.Net.Http.HttpClient client, System.Net.Http.HttpRequestMessage request, string url); partial void PrepareRequest(System.Net.Http.HttpClient client, System.Net.Http.HttpRequestMessage request, System.Text.StringBuilder urlBuilder); partial void ProcessResponse(System.Net.Http.HttpClient client, System.Net.Http.HttpResponseMessage response); - /// A server side error occurred. public System.Threading.Tasks.Task> GetAsync() { @@ -63,8 +66,10 @@ private Newtonsoft.Json.JsonSerializerSettings CreateSerializerSettings() request_.Headers.Accept.Add(System.Net.Http.Headers.MediaTypeWithQualityHeaderValue.Parse("application/json")); PrepareRequest(client_, request_, urlBuilder_); + var url_ = urlBuilder_.ToString(); request_.RequestUri = new System.Uri(url_, System.UriKind.RelativeOrAbsolute); + PrepareRequest(client_, request_, url_); var response_ = await client_.SendAsync(request_, System.Net.Http.HttpCompletionOption.ResponseHeadersRead, cancellationToken).ConfigureAwait(false); @@ -83,7 +88,7 @@ private Newtonsoft.Json.JsonSerializerSettings CreateSerializerSettings() var status_ = (int)response_.StatusCode; if (status_ == 200) { - var objectResponse_ = await ReadObjectResponseAsync>(response_, headers_).ConfigureAwait(false); + var objectResponse_ = await ReadObjectResponseAsync>(response_, headers_, cancellationToken).ConfigureAwait(false); if (objectResponse_.Object == null) { throw new ApiException("Response was null which was not expected.", status_, objectResponse_.Text, headers_, null); @@ -92,7 +97,7 @@ private Newtonsoft.Json.JsonSerializerSettings CreateSerializerSettings() } else { - var responseData_ = response_.Content == null ? null : await response_.Content.ReadAsStringAsync().ConfigureAwait(false); + var responseData_ = response_.Content == null ? null : await response_.Content.ReadAsStringAsync().ConfigureAwait(false); throw new ApiException("The HTTP status code of the response was not expected (" + status_ + ").", status_, responseData_, headers_, null); } } @@ -125,7 +130,7 @@ public ObjectResponseResult(T responseObject, string responseText) public bool ReadResponseAsString { get; set; } - protected virtual async System.Threading.Tasks.Task> ReadObjectResponseAsync(System.Net.Http.HttpResponseMessage response, System.Collections.Generic.IReadOnlyDictionary> headers) + protected virtual async System.Threading.Tasks.Task> ReadObjectResponseAsync(System.Net.Http.HttpResponseMessage response, System.Collections.Generic.IReadOnlyDictionary> headers, System.Threading.CancellationToken cancellationToken) { if (response == null || response.Content == null) { @@ -171,7 +176,7 @@ private string ConvertToString(object value, System.Globalization.CultureInfo cu { if (value == null) { - return null; + return ""; } if (value is System.Enum) @@ -190,7 +195,8 @@ private string ConvertToString(object value, System.Globalization.CultureInfo cu } } - return System.Convert.ToString(System.Convert.ChangeType(value, System.Enum.GetUnderlyingType(value.GetType()), cultureInfo)); + var converted = System.Convert.ToString(System.Convert.ChangeType(value, System.Enum.GetUnderlyingType(value.GetType()), cultureInfo)); + return converted == null ? string.Empty : converted; } } else if (value is bool) @@ -208,11 +214,11 @@ private string ConvertToString(object value, System.Globalization.CultureInfo cu } var result = System.Convert.ToString(value, cultureInfo); - return (result is null) ? string.Empty : result; + return result == null ? "" : result; } } - [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "10.2.1.0 (Newtonsoft.Json v12.0.0.0)")] + [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "10.5.2.0 (Newtonsoft.Json v12.0.0.0)")] public partial class WeatherForecast : System.ComponentModel.INotifyPropertyChanged { private System.DateTime _date; @@ -224,11 +230,11 @@ public partial class WeatherForecast : System.ComponentModel.INotifyPropertyChan public System.DateTime Date { get { return _date; } - set + set { if (_date != value) { - _date = value; + _date = value; RaisePropertyChanged(); } } @@ -238,11 +244,11 @@ public System.DateTime Date public int TemperatureC { get { return _temperatureC; } - set + set { if (_temperatureC != value) { - _temperatureC = value; + _temperatureC = value; RaisePropertyChanged(); } } @@ -252,11 +258,11 @@ public int TemperatureC public int TemperatureF { get { return _temperatureF; } - set + set { if (_temperatureF != value) { - _temperatureF = value; + _temperatureF = value; RaisePropertyChanged(); } } @@ -266,24 +272,24 @@ public int TemperatureF public string Summary { get { return _summary; } - set + set { if (_summary != value) { - _summary = value; + _summary = value; RaisePropertyChanged(); } } } - public string ToJson() + public string ToJson() { - return Newtonsoft.Json.JsonConvert.SerializeObject(this); + return Newtonsoft.Json.JsonConvert.SerializeObject(this, new Newtonsoft.Json.JsonSerializerSettings()); } public static WeatherForecast FromJson(string data) { - return Newtonsoft.Json.JsonConvert.DeserializeObject(data); + return Newtonsoft.Json.JsonConvert.DeserializeObject(data, new Newtonsoft.Json.JsonSerializerSettings()); } public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged; @@ -297,7 +303,7 @@ protected virtual void RaisePropertyChanged([System.Runtime.CompilerServices.Cal } - [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.8.2.0 (NJsonSchema v10.2.1.0 (Newtonsoft.Json v12.0.0.0))")] + [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.14.5.0 (NJsonSchema v10.5.2.0 (Newtonsoft.Json v12.0.0.0))")] public partial class ApiException : System.Exception { public int StatusCode { get; private set; } @@ -310,7 +316,7 @@ public ApiException(string message, int statusCode, string response, System.Coll : base(message + "\n\nStatus: " + statusCode + "\nResponse: \n" + ((response == null) ? "(null)" : response.Substring(0, response.Length >= 512 ? 512 : response.Length)), innerException) { StatusCode = statusCode; - Response = response; + Response = response; Headers = headers; } @@ -320,7 +326,7 @@ public override string ToString() } } - [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.8.2.0 (NJsonSchema v10.2.1.0 (Newtonsoft.Json v12.0.0.0))")] + [System.CodeDom.Compiler.GeneratedCode("NSwag", "13.14.5.0 (NJsonSchema v10.5.2.0 (Newtonsoft.Json v12.0.0.0))")] public partial class ApiException : ApiException { public TResult Result { get; private set; } @@ -338,4 +344,5 @@ public ApiException(string message, int statusCode, string response, System.Coll #pragma warning restore 1573 #pragma warning restore 472 #pragma warning restore 114 -#pragma warning restore 108 \ No newline at end of file +#pragma warning restore 108 +#pragma warning restore 3016 \ No newline at end of file diff --git a/samples/WithMiddleware/Sample.AspNetCore31/openapi.json b/samples/WithMiddleware/Sample.AspNetCore31/openapi.json index f69c7ca45d..fe8039f791 100644 --- a/samples/WithMiddleware/Sample.AspNetCore31/openapi.json +++ b/samples/WithMiddleware/Sample.AspNetCore31/openapi.json @@ -1,5 +1,5 @@ { - "x-generator": "NSwag v13.8.2.0 (NJsonSchema v10.2.1.0 (Newtonsoft.Json v9.0.0.0))", + "x-generator": "NSwag v13.14.5.0 (NJsonSchema v10.5.2.0 (Newtonsoft.Json v9.0.0.0))", "openapi": "3.0.0", "info": { "title": "My Sample App", diff --git a/samples/WithMiddleware/Sample.NetOwinMiddleware/Sample.NetOwinMiddleware.csproj b/samples/WithMiddleware/Sample.NetOwinMiddleware/Sample.NetOwinMiddleware.csproj index e51e0b3bfb..f519c48924 100644 --- a/samples/WithMiddleware/Sample.NetOwinMiddleware/Sample.NetOwinMiddleware.csproj +++ b/samples/WithMiddleware/Sample.NetOwinMiddleware/Sample.NetOwinMiddleware.csproj @@ -1,5 +1,4 @@  - Debug @@ -44,46 +43,8 @@ - - ..\..\packages\Microsoft.Owin.4.0.1\lib\net45\Microsoft.Owin.dll - - - ..\..\packages\Microsoft.Owin.FileSystems.3.0.1\lib\net45\Microsoft.Owin.FileSystems.dll - - - ..\..\packages\Microsoft.Owin.Host.SystemWeb.4.0.1\lib\net45\Microsoft.Owin.Host.SystemWeb.dll - - - ..\..\packages\Microsoft.Owin.StaticFiles.3.0.1\lib\net45\Microsoft.Owin.StaticFiles.dll - - - ..\..\packages\Namotion.Reflection.2.0.3\lib\net45\Namotion.Reflection.dll - - - ..\..\packages\NJsonSchema.10.5.2\lib\net45\NJsonSchema.dll - - - ..\..\packages\NSwag.AspNet.Owin.13.14.5\lib\net45\NSwag.AspNet.Owin.dll - - - ..\..\packages\NSwag.Core.13.14.5\lib\net45\NSwag.Core.dll - - - ..\..\packages\NSwag.Generation.13.14.5\lib\net45\NSwag.Generation.dll - True - - - ..\..\packages\NSwag.Generation.WebApi.13.14.5\lib\net45\NSwag.Generation.WebApi.dll - True - - - ..\..\packages\Owin.1.0\lib\net40\Owin.dll - - - ..\..\packages\Microsoft.AspNet.WebApi.Client.5.2.7\lib\net45\System.Net.Http.Formatting.dll - @@ -94,12 +55,6 @@ - - ..\..\packages\Microsoft.AspNet.WebApi.Core.5.2.7\lib\net45\System.Web.Http.dll - - - ..\..\packages\Microsoft.AspNet.WebApi.Owin.5.2.7\lib\net45\System.Web.Http.Owin.dll - @@ -108,17 +63,6 @@ - - - ..\..\packages\Newtonsoft.Json.11.0.1\lib\net45\Newtonsoft.Json.dll - - - ..\..\packages\Microsoft.AspNet.WebApi.WebHost.5.2.4\lib\net45\System.Web.Http.WebHost.dll - - - ..\..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.2.0.0\lib\net45\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.dll - - @@ -129,7 +73,6 @@ - Web.config @@ -141,6 +84,26 @@ + + + + + + + + + + + + + + + + + + + + 10.0 $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) @@ -166,12 +129,6 @@ - - - This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. - - - - + + - @@ -46,22 +46,17 @@ - + + + + + - - - - - - - - - - - - + + - + + \ No newline at end of file diff --git a/samples/WithMiddleware/Sample.NetOwinMiddleware/packages.config b/samples/WithMiddleware/Sample.NetOwinMiddleware/packages.config deleted file mode 100644 index a90c8ef287..0000000000 --- a/samples/WithMiddleware/Sample.NetOwinMiddleware/packages.config +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/Controllers/ValuesController.cs b/samples/WithoutMiddleware/Sample.AspNetCore31/Controllers/ValuesController.cs similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/Controllers/ValuesController.cs rename to samples/WithoutMiddleware/Sample.AspNetCore31/Controllers/ValuesController.cs diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/Program.cs b/samples/WithoutMiddleware/Sample.AspNetCore31/Program.cs similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/Program.cs rename to samples/WithoutMiddleware/Sample.AspNetCore31/Program.cs diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/Properties/launchSettings.json b/samples/WithoutMiddleware/Sample.AspNetCore31/Properties/launchSettings.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/Properties/launchSettings.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/Properties/launchSettings.json diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/Sample.AspNetCore21.csproj b/samples/WithoutMiddleware/Sample.AspNetCore31/Sample.AspNetCore31.csproj similarity index 67% rename from samples/WithoutMiddleware/Sample.AspNetCore21/Sample.AspNetCore21.csproj rename to samples/WithoutMiddleware/Sample.AspNetCore31/Sample.AspNetCore31.csproj index 2767460a3e..fe1a5a04fd 100644 --- a/samples/WithoutMiddleware/Sample.AspNetCore21/Sample.AspNetCore21.csproj +++ b/samples/WithoutMiddleware/Sample.AspNetCore31/Sample.AspNetCore31.csproj @@ -1,17 +1,13 @@ - netcoreapp2.1 + netcoreapp3.1 - - - - diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/Startup.cs b/samples/WithoutMiddleware/Sample.AspNetCore31/Startup.cs similarity index 88% rename from samples/WithoutMiddleware/Sample.AspNetCore21/Startup.cs rename to samples/WithoutMiddleware/Sample.AspNetCore31/Startup.cs index 0020aacda3..21700409df 100644 --- a/samples/WithoutMiddleware/Sample.AspNetCore21/Startup.cs +++ b/samples/WithoutMiddleware/Sample.AspNetCore31/Startup.cs @@ -25,7 +25,9 @@ public Startup(IConfiguration configuration) // This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { - services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1); + services + .AddMvc(options => options.EnableEndpointRouting = false) + .SetCompatibilityVersion(CompatibilityVersion.Version_2_1); } // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/appsettings.Development.json b/samples/WithoutMiddleware/Sample.AspNetCore31/appsettings.Development.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/appsettings.Development.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/appsettings.Development.json diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/appsettings.json b/samples/WithoutMiddleware/Sample.AspNetCore31/appsettings.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/appsettings.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/appsettings.json diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_assembly.nswag b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_assembly.nswag similarity index 96% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_assembly.nswag rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_assembly.nswag index 0ffecb6bab..d532559acd 100644 --- a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_assembly.nswag +++ b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_assembly.nswag @@ -48,7 +48,7 @@ "output": "nswag_assembly_swagger.json", "outputType": "Swagger2", "assemblyPaths": [ - "bin/$(configuration)/netcoreapp2.1/Sample.AspNetCore21.dll" + "bin/$(configuration)/netcoreapp3.1/Sample.AspNetCore31.dll" ], "assemblyConfig": null, "referencePaths": [], diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_assembly_swagger.json b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_assembly_swagger.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_assembly_swagger.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_assembly_swagger.json diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_project.nswag b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_project.nswag similarity index 96% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_project.nswag rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_project.nswag index 99f950fe0b..f7593cc209 100644 --- a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_project.nswag +++ b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_project.nswag @@ -1,9 +1,9 @@ { - "runtime": "NetCore21", + "runtime": "NetCore31", "defaultVariables": "configuration=Debug", "documentGenerator": { "aspNetCoreToOpenApi": { - "project": "Sample.AspNetCore21.csproj", + "project": "Sample.AspNetCore31.csproj", "msBuildProjectExtensionsPath": null, "configuration": "$(configuration)", "runtime": null, diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_project_swagger.json b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_project_swagger.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_project_swagger.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_project_swagger.json diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_reflection.nswag b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_reflection.nswag similarity index 96% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_reflection.nswag rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_reflection.nswag index 1f39a63f70..af3980aa53 100644 --- a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_reflection.nswag +++ b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_reflection.nswag @@ -44,7 +44,7 @@ "output": "nswag_reflection_swagger.json", "outputType": "Swagger2", "assemblyPaths": [ - "bin/$(configuration)/netcoreapp2.1/Sample.AspNetCore21.dll" + "bin/$(configuration)/netcoreapp3.1/Sample.AspNetCore31.dll" ], "assemblyConfig": null, "referencePaths": [], diff --git a/samples/WithoutMiddleware/Sample.AspNetCore21/nswag_reflection_swagger.json b/samples/WithoutMiddleware/Sample.AspNetCore31/nswag_reflection_swagger.json similarity index 100% rename from samples/WithoutMiddleware/Sample.AspNetCore21/nswag_reflection_swagger.json rename to samples/WithoutMiddleware/Sample.AspNetCore31/nswag_reflection_swagger.json diff --git a/src/NSwag.Min.sln b/src/NSwag.Min.sln index 524dc61eda..eb02e15175 100644 --- a/src/NSwag.Min.sln +++ b/src/NSwag.Min.sln @@ -45,7 +45,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Generation.AspNetCore EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Generation.AspNetCore.Tests.Web", "NSwag.Generation.AspNetCore.Tests.Web\NSwag.Generation.AspNetCore.Tests.Web.csproj", "{C56AC38A-513B-40C6-AEB8-0146BB5B2888}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NETCore21", "NSwag.Sample.NETCore21\NSwag.Sample.NETCore21.csproj", "{B024633F-AA96-4551-AB18-2EF9650425AF}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NETCore31", "NSwag.Sample.NETCore31\NSwag.Sample.NETCore31.csproj", "{B024633F-AA96-4551-AB18-2EF9650425AF}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Core.Yaml.Tests", "NSwag.Core.Yaml.Tests\NSwag.Core.Yaml.Tests.csproj", "{9829DFE2-7F49-40E3-B6A5-AEBB42D1DB33}" EndProject @@ -69,10 +69,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.AssemblyLoader.Tests" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Generation.Tests", "NSwag.Generation.Tests\NSwag.Generation.Tests.csproj", "{3A6CA187-AD6F-438C-9E5B-B2771F75AF41}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NET50", "NSwag.Sample.NET50\NSwag.Sample.NET50.csproj", "{F109D48B-A2FF-497D-8374-FEA60C5F2365}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NETCore31", "NSwag.Sample.NETCore31\NSwag.Sample.NETCore31.csproj", "{FC20849C-915D-411B-8CFB-915B7751D898}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NET60", "NSwag.Sample.NET60\NSwag.Sample.NET60.csproj", "{7C9814BB-5B98-43F1-9CD2-4C55CEB9DFBF}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NSwag.Sample.NET60Minimal", "NSwag.Sample.NET60Minimal\NSwag.Sample.NET60Minimal.csproj", "{FA78E42D-F49F-45E3-820E-331FB8E34195}" @@ -556,42 +552,6 @@ Global {3A6CA187-AD6F-438C-9E5B-B2771F75AF41}.ReleaseTypeScriptStrict|x64.Build.0 = Release|Any CPU {3A6CA187-AD6F-438C-9E5B-B2771F75AF41}.ReleaseTypeScriptStrict|x86.ActiveCfg = Release|Any CPU {3A6CA187-AD6F-438C-9E5B-B2771F75AF41}.ReleaseTypeScriptStrict|x86.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|Any CPU.Build.0 = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|x64.ActiveCfg = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|x64.Build.0 = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|x86.ActiveCfg = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Debug|x86.Build.0 = Debug|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|Any CPU.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|Any CPU.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|x64.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|x64.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|x86.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.Release|x86.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|Any CPU.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|Any CPU.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|x64.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|x64.Build.0 = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|x86.ActiveCfg = Release|Any CPU - {F109D48B-A2FF-497D-8374-FEA60C5F2365}.ReleaseTypeScriptStrict|x86.Build.0 = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|Any CPU.Build.0 = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|x64.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|x64.Build.0 = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|x86.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Debug|x86.Build.0 = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|Any CPU.ActiveCfg = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|Any CPU.Build.0 = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|x64.ActiveCfg = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|x64.Build.0 = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|x86.ActiveCfg = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.Release|x86.Build.0 = Release|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|Any CPU.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|Any CPU.Build.0 = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|x64.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|x64.Build.0 = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|x86.ActiveCfg = Debug|Any CPU - {FC20849C-915D-411B-8CFB-915B7751D898}.ReleaseTypeScriptStrict|x86.Build.0 = Debug|Any CPU {7C9814BB-5B98-43F1-9CD2-4C55CEB9DFBF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {7C9814BB-5B98-43F1-9CD2-4C55CEB9DFBF}.Debug|Any CPU.Build.0 = Debug|Any CPU {7C9814BB-5B98-43F1-9CD2-4C55CEB9DFBF}.Debug|x64.ActiveCfg = Debug|Any CPU @@ -659,8 +619,6 @@ Global {DCAF8B88-E36F-48F8-AD0E-0F9B42E9FEB6} = {49A70E20-FF73-451D-BBE8-7680EDCF007B} {06B5C478-0ACC-4088-97B6-891C4F35EBBC} = {D8CC0D1C-8DAC-49FE-AA78-C028DC124DD5} {3A6CA187-AD6F-438C-9E5B-B2771F75AF41} = {D8CC0D1C-8DAC-49FE-AA78-C028DC124DD5} - {F109D48B-A2FF-497D-8374-FEA60C5F2365} = {A0338E8D-A4A3-4380-9FF7-1D0BDC260E31} - {FC20849C-915D-411B-8CFB-915B7751D898} = {A0338E8D-A4A3-4380-9FF7-1D0BDC260E31} {7C9814BB-5B98-43F1-9CD2-4C55CEB9DFBF} = {A0338E8D-A4A3-4380-9FF7-1D0BDC260E31} {FA78E42D-F49F-45E3-820E-331FB8E34195} = {A0338E8D-A4A3-4380-9FF7-1D0BDC260E31} EndGlobalSection