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

Improve generator distribution for sized schemas #748

Merged
merged 1 commit into from Aug 30, 2022

Commits on Aug 30, 2022

  1. improve generator distribution for sized schemas

    We want the same distribution for `gen/vector` for both
    these cases:
    1. only :min is provided
    2. no min-max opts are passed.
    
    This fixes generation for 1 by using + to shift the length
    distribution instead of squashing it via clojure.core/max.
    
    Same approach as clojure.test.check.generators/coll-distinct-by:
      https://github.com/clojure/test.check/blob/b6a318af92e836f1f20960f38a5944168b88d60d/src/main/clojure/clojure/test/check/generators.cljc#L799
    frenchy64 committed Aug 30, 2022
    Configuration menu
    Copy the full SHA
    83f7999 View commit details
    Browse the repository at this point in the history