Skip to content

Conversation

@Aragas
Copy link
Contributor

@Aragas Aragas commented Nov 1, 2023

I'm (not) sorry
We also need tests for unmanaged/int types

@Aragas Aragas changed the title Added IHasRandomId for unmanaged Added IHasRandomValueGenerator Nov 1, 2023
@Aragas Aragas changed the title Added IHasRandomValueGenerator Augment: IHasRandomValueGenerator Nov 1, 2023
Copy link
Owner

@erri120 erri120 left a comment

Choose a reason for hiding this comment

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

Besides having to adapt this code to latest main, I don't think IHasRandomValueGenerator should have a TRandom type argument. 99.999999% of the time it's going to be System.Random. If you remove the type argument, we can also use Random.Shared instead of instantiating a new Random object every time.

# Conflicts:
#	tests/TransparentValueObjects.Tests/ValueObjectIncrementalSourceGeneratorTests/BaseTests.cs
Removed GenerateRandomValue
Added GetRandom
@Aragas
Copy link
Contributor Author

Aragas commented Nov 9, 2023

Should be up to date now

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.

2 participants