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

Generators Returning Same Value #7

Open
markbastian opened this issue Jul 7, 2020 · 0 comments
Open

Generators Returning Same Value #7

markbastian opened this issue Jul 7, 2020 · 0 comments

Comments

@markbastian
Copy link

Some generators always produce the same value when sampled.

 (require '[clojure.spec.gen.alpha :as gen])
  (require '[talltale.core :as tc])

  ;Returns a bunch of names
  (gen/sample (tc/first-name-gen))
  ;Returns the same value. Each evaluation produces a new value, but that value is repeated for all samples.
  (gen/sample (tc/date-of-birth-gen (tc/age)))
  ;Same behavior here
  (gen/sample (tc/email-gen :en (tc/first-name) (tc/last-name)))

I would expect all samples to be different.

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

1 participant