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

Is it possible to have default behaviour for properties not defined? #47

Closed
Ian1971 opened this issue Dec 20, 2016 · 1 comment
Closed

Comments

@Ian1971
Copy link

Ian1971 commented Dec 20, 2016

For example on quite a wide class I only really want to define a rule for a couple of properties and and the rest can be random strings.
So something like

faker.DefaultRuleFor<string>(f => "a string")

@bchavez
Copy link
Owner

bchavez commented Dec 20, 2016

Related #38

Feature is now implemented in v8.0.3 available on NuGet soon. The new method is:

RuleForType(typeof(string), f => "a string")

Thanks!
🎧 🎶 Antiserum & Mayhem - Trippy

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

No branches or pull requests

2 participants