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

Feature Request: ExUnit seeds for Faker #333

Open
michaelfich opened this issue Apr 21, 2020 · 1 comment
Open

Feature Request: ExUnit seeds for Faker #333

michaelfich opened this issue Apr 21, 2020 · 1 comment

Comments

@michaelfich
Copy link
Contributor

Would it be possible, or even desired, to add a feature which would let you take the seed number from ExUnit, and use it to seed the random data supplied by Faker during tests? It would make it really helpful to track down the results of flaky tests.

@igas
Copy link
Member

igas commented May 4, 2020

I think you can achieve this with something similar to what we do in faker tests itself.

Application.put_env(:faker, :random_module, Faker.Random.Test)

I'm currently not using faker, if you want to give it a shot and hit roadblocks don't hesitate to ask here, I'll try to help.

If you manage to solve it with this feel free to post it here or send PR so other people can use it too.

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