Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion trie/trie_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,9 @@ func TestRandomCases(t *testing.T) {
// Instances of this test are created by Generate.
type randTest []randTestStep

// compile-time interface check
var _ quick.Generator = (randTest)(nil)

type randTestStep struct {
op int
key []byte // for opUpdate, opDelete, opGet
Expand All @@ -394,7 +397,7 @@ const (
func (randTest) Generate(r *rand.Rand, size int) reflect.Value {
var finishedFn = func() bool {
size--
return size > 0
return size == 0
}
return reflect.ValueOf(generateSteps(finishedFn, r))
}
Expand Down