Skip to content

Commit

Permalink
fix: run subtests in parallel
Browse files Browse the repository at this point in the history
  • Loading branch information
notanatol committed Jan 12, 2024
1 parent 0624ea4 commit 724479c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/file/joiner/joiner_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1226,6 +1226,7 @@ func TestJoinerRedundancyMultilevel(t *testing.T) {
getter.StrategyTimeout = 100 * time.Millisecond

test := func(t *testing.T, rLevel redundancy.Level, encrypt bool, size int) {
t.Helper()
store := mockstorer.NewForgettingStore(inmemchunkstore.New())
testutil.CleanupCloser(t, store)
seed, err := pseudorand.NewSeed()
Expand Down Expand Up @@ -1339,6 +1340,7 @@ func TestJoinerRedundancyMultilevel(t *testing.T) {
if r2level[rLevel] != levels || encrypt != encryptChunk[rLevel] {
t.Skip("skipping to save time")
}
t.Parallel()
test(t, rLevel, encrypt, chunkCnt)
})
switch levels {
Expand All @@ -1350,6 +1352,7 @@ func TestJoinerRedundancyMultilevel(t *testing.T) {
continue
}
t.Run(fmt.Sprintf("encrypt=%v levels=%d chunks=%d full", encrypt, levels, chunkCnt), func(t *testing.T) {
t.Parallel()
test(t, rLevel, encrypt, chunkCnt)
})
}
Expand Down

0 comments on commit 724479c

Please sign in to comment.