I am trying to generate some address using Bogus. I see the below error
UnitTest1.cs(20, 14): [CS0411] The type arguments for method 'Faker<Address>.RuleFor<TProperty>(Expression<Func<Address, TProperty>>, Func<Faker, Address, TProperty>)' cannot be inferred from the usage. Try specifying the type arguments explicitly.
What possible solutions have you considered?
Tried debugging - not sure why it's so hard to generate some random addresses.
Do you have sample code to show what you're trying to do?
Below is the sample code
var address = new Faker<Address>()
.RuleFor(a => a.City, f => f.Address.City)
.RuleFor(a => a.State, f => f.Address.State)
.RuleFor(a => a.Latitude, f => f.Address.Latitude)
.RuleFor(a => a.Longitude, f => f.Address.Longitude)
.Generate(100);
(Please be complete. Provide all code necessary to run your example in LINQPad.)(The more complete code examples are, the more accurate answers will be.)(https://www.linqpad.net)
Version Information
What locale are you using with Bogus?
No locale. (Tried using "en" but no luck)
What's the problem?
I am trying to generate some address using Bogus. I see the below error
What possible solutions have you considered?
Tried debugging - not sure why it's so hard to generate some random addresses.
Do you have sample code to show what you're trying to do?
Below is the sample code
(Please be complete. Provide all code necessary to run your example in LINQPad.) (The more complete code examples are, the more accurate answers will be.) (https://www.linqpad.net)