Skip to content

Commit

Permalink
Tweaks.
Browse files Browse the repository at this point in the history
Enable generation of OpenAPI.

Extend.

TypeBase and TypeInfo to get all arguments in.

Fix IsStatic.

Fix test.

Updat packages.

Setup generation,

Support multi line XML comments.

Use OpenApiSchemaContext.

Use context.

Drop Decorator as seperate class.

SchemaID resolving backup (property.Name).

start using walker.

Support EnergyType.

Use walker.

Clean-up resolve schema.

Simplify visit.

Extend resolving of properties.

Improvements in enum generation.

Fix test.

Support OneOf/derived types.

Resolve AllOff.

clean-up project file

Updage Microsoft.OpenApi dependencies.

update versions.

Adjust build.
  • Loading branch information
Corniel committed Jan 9, 2024
1 parent 645ca9b commit 415a591
Show file tree
Hide file tree
Showing 66 changed files with 2,681 additions and 239 deletions.
5 changes: 5 additions & 0 deletions qowaiv-code-generation.sln
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "props", "props", "{8C1F30B9
props\nopackage.props = props\nopackage.props
props\package.props = props\package.props
EndProjectSection
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Qowaiv.CodeGeneration.OpenApi", "src\Qowaiv.CodeGeneration.OpenApi\Qowaiv.CodeGeneration.OpenApi.csproj", "{A97B0E0B-57DD-4F96-A477-FE4DCEE2F8E8}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand All @@ -53,6 +54,10 @@ Global
{6EA317E7-ED85-48C3-A585-05980E16C2EA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6EA317E7-ED85-48C3-A585-05980E16C2EA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6EA317E7-ED85-48C3-A585-05980E16C2EA}.Release|Any CPU.Build.0 = Release|Any CPU
{A97B0E0B-57DD-4F96-A477-FE4DCEE2F8E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A97B0E0B-57DD-4F96-A477-FE4DCEE2F8E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A97B0E0B-57DD-4F96-A477-FE4DCEE2F8E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A97B0E0B-57DD-4F96-A477-FE4DCEE2F8E8}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
124 changes: 82 additions & 42 deletions shared/Guard.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using Qowaiv.CodeGeneration;
using System.IO;
using System.IO;

namespace FluentAssertions;

Expand All @@ -21,14 +20,15 @@ public class CodeAssertions
writer.Flush();

var csharp = Encoding.UTF8.GetString(stream.ToArray());
csharp.Should().Be(Normalize(content, settings ?? new()), because, becauseArgs);
settings ??= new();
csharp.Should().Be(Normalize(content, settings), because, becauseArgs);

return new(this);

static string Normalize(string content, CSharpWriterSettings settings)
{
var lines = content.Split(new[] { "\r\n", "\n" }, StringSplitOptions.None);
content = string.Join((settings).NewLine, lines);
content = string.Join(settings.NewLine, lines);
return content;
}
}
Expand Down
Loading

0 comments on commit 415a591

Please sign in to comment.