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

Support for min/max_count option override for DataGenerator #6

Open
graste opened this issue Jul 30, 2015 · 3 comments
Open

Support for min/max_count option override for DataGenerator #6

graste opened this issue Jul 30, 2015 · 3 comments

Comments

@graste
Copy link
Member

graste commented Jul 30, 2015

Would be nice if one can specify via options whether an embedded entity is always created or not. At the moment it's a random number of entries for an EmbeddedEntityListAttribute between min_count and max_count attribute option value with a default of 0 for min_count. At least the minimum number of embedded entities to create in fake data would be nice.

@MrHash
Copy link
Contributor

MrHash commented Aug 1, 2015

Given that the min_count and inline_mode is supported wouldn't it make sense to use those options? or the mandatory option? Empty entity lists are valid so better to generate more data if you want to ensure data is present?

@graste
Copy link
Member Author

graste commented Sep 11, 2015

Actually depends on use case. I had one where I wanted entities with as many embedded entities as possible for each embedded type if I could've configured that. So I set the max count to the number of embedded entities I needed and then generated multiple root entities to have a chance of getting the different embedded types for my export test data that I needed to be full for tests.

@MrHash
Copy link
Contributor

MrHash commented Sep 11, 2015

If you wanted to override, how would you specify the number of embedded types to render? And would this apply to all root entities when generating several at the same time?

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

No branches or pull requests

2 participants