diff --git a/pkg/file/redundancy/getter/getter_test.go b/pkg/file/redundancy/getter/getter_test.go index 2b85d11c589..60f2dbf941c 100644 --- a/pkg/file/redundancy/getter/getter_test.go +++ b/pkg/file/redundancy/getter/getter_test.go @@ -37,20 +37,20 @@ func TestGetterRACE(t *testing.T) { } var tcs []getterTest - for bufSize := 3; bufSize <= 128; bufSize += 21 { - for shardCnt := bufSize/2 + 1; shardCnt <= bufSize; shardCnt += 21 { + for bufSize := 3; bufSize <= 128; bufSize += 50 { + for shardCnt := bufSize/2 + 1; shardCnt <= bufSize; shardCnt += 50 { parityCnt := bufSize - shardCnt erasures := mrand.Perm(parityCnt - 1) - if len(erasures) > 3 { - erasures = erasures[:3] + if len(erasures) > 2 { + erasures = erasures[:2] } for _, erasureCnt := range erasures { tcs = append(tcs, getterTest{bufSize, shardCnt, erasureCnt}) } tcs = append(tcs, getterTest{bufSize, shardCnt, parityCnt}, getterTest{bufSize, shardCnt, parityCnt + 1}) erasures = mrand.Perm(shardCnt - 1) - if len(erasures) > 3 { - erasures = erasures[:3] + if len(erasures) > 2 { + erasures = erasures[:2] } for _, erasureCnt := range erasures { tcs = append(tcs, getterTest{bufSize, shardCnt, erasureCnt + parityCnt + 1}) @@ -156,7 +156,7 @@ func testDecodingFallback(t *testing.T, s getter.Strategy, strict bool) { bufSize := 12 shardCnt := 6 - store := mockstorer.NewDelayedStore(inmem.New()) + store := mockstorer.NewDelayedStore(inmem.New()) buf := make([][]byte, bufSize) addrs := initData(t, buf, shardCnt, store)