This tests the performance of shrinking a list of lists, testing the false property that the sum of lengths of the element lists is at most 10.
The reason this is interesting is that it has lots of local minima under
pure deletion based approaches. e.g. [[0], ..., [0]]
and [[0, ..., 0]]
are
both minima for this under anything that can only make individual elements
smaller.
Some libraries, e.g. Hypothesis and jqwik, can shrink this reliably to
a single list of 11 elements: [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0]]
.
Library | Code | Report |
---|---|---|
Americium | NestedListsTest.java | nestedLists.md |
jqwik | NestedListsProperties.java | nestedlists.md |
fast-check | nestedlist.js | nestedlists.md |
CsCheck | ShrinkingChallengeTests.cs | nestedlists.md |
elm-test | NestedLists.elm | nestedLists.md |