Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support .net 6 DateOnly TimeOnly structs #84

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pdevito3
Copy link

@pdevito3 pdevito3 commented Apr 30, 2022

fixes #76

tried to follow your pattern throughout and included a test for the new type. I did have to do some minor update fluent assertion updates as well.

let me know if you have any questions or concerns!

entity2.Name.Should().Be(entity1.Name);
entity2.DeprecationDate.Should().BeCloseTo(entity1.DeprecationDate, 500);
entity2.Name.Should().Be(entity1.Name);
entity2.DeprecationDate.Should().BeCloseTo(entity1.DeprecationDate, TimeSpan.FromMilliseconds(500));
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new fluent assertion syntax

@@ -35,7 +35,7 @@ public void TestAutoFaker()
},
options => options
.Using<string>(context => context.Subject.Should().NotBeNull())
.When(info => info.SelectedMemberPath == "Status")
.When(info => info.Path.Contains("Status"))
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new fluent assertion syntax

@@ -11,7 +11,7 @@


<ItemGroup>
<PackageReference Include="FluentAssertions" Version="5.10.3" />
<PackageReference Include="FluentAssertions" Version="6.6.0" />
Copy link
Author

@pdevito3 pdevito3 Apr 30, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needed to update FA to accommodate the dateonly timeonly handling

@304NotModified
Copy link

this looks like a great feature! polite bump @nickdodd79

@pdevito3
Copy link
Author

I don't think he's maintaining the lib anymore. I made a fork that can handle this if you want to use it.

https://www.nuget.org/packages/AutoBogusLifesupport

https://github.com/pdevito3/AutoBogus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Generating a class with a .NET 6 DateOnly property fails
2 participants