testerasure: fix column selection
previous test was sometimes failing, and often failing if changed to dataSetSize = BlockSize * 20 Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
This commit is contained in:
parent
cc52c7036f
commit
0001bbdd92
|
@ -61,7 +61,7 @@ suite "Erasure encode/decode":
|
||||||
let encoded = await encode(buffers, parity)
|
let encoded = await encode(buffers, parity)
|
||||||
|
|
||||||
var
|
var
|
||||||
column = rng.rand((encoded.len div encoded.steps) - 1) # random column
|
column = rng.rand(encoded.steps - 1) # random column
|
||||||
dropped: seq[Cid]
|
dropped: seq[Cid]
|
||||||
|
|
||||||
for _ in 0..<encoded.ecM:
|
for _ in 0..<encoded.ecM:
|
||||||
|
@ -89,7 +89,7 @@ suite "Erasure encode/decode":
|
||||||
let encoded = await encode(buffers, parity)
|
let encoded = await encode(buffers, parity)
|
||||||
|
|
||||||
var
|
var
|
||||||
column = rng.rand((encoded.len div encoded.steps) - 1) # random column
|
column = rng.rand(encoded.steps - 1) # random column
|
||||||
dropped: seq[Cid]
|
dropped: seq[Cid]
|
||||||
|
|
||||||
for _ in 0..<encoded.ecM + 1:
|
for _ in 0..<encoded.ecM + 1:
|
||||||
|
|
Loading…
Reference in New Issue