spock-genesis icon indicating copy to clipboard operation
spock-genesis copied to clipboard

Gen.list ignores min if source is exhausted

Open drdamour opened this issue 7 years ago • 0 comments

i ran into a lot of random test failures for something that had

static Generator<List<Integer>> ints(){

    Gen.list(
        Gen.these(1,2,3),
            2,
            2
    )
}

I expected to only get 1 entry (no entrys that violated my rules of min=2) but got 2, 1 violation the rules.

workaround is to append a filter after

drdamour avatar Sep 28 '17 21:09 drdamour