EnableLargeSectors: restore previous supported proof types.

This commit is contained in:
Raúl Kripalani 2021-08-20 18:07:25 +01:00
parent 0030e208a0
commit 342134f853
2 changed files with 10 additions and 3 deletions

View File

@ -15,7 +15,7 @@ func TestStorageDealMissingBlock(t *testing.T) {
ctx := context.Background()
// enable 512MiB proofs so we can conduct larger transfers.
kit.EnableLargeSectors()
kit.EnableLargeSectors(t)
kit.QuietMiningLogs()
client, miner, ens := kit.EnsembleMinimal(t,

View File

@ -1,6 +1,8 @@
package kit
import (
"testing"
"github.com/filecoin-project/go-state-types/abi"
"github.com/filecoin-project/lotus/chain/actors/policy"
@ -8,9 +10,14 @@ import (
// EnableLargeSectors enables 512MiB sectors. This is useful in combination with
// mock proofs, for testing larger transfers.
func EnableLargeSectors() {
func EnableLargeSectors(t *testing.T) {
policy.SetSupportedProofTypes(
abi.RegisteredSealProof_StackedDrg2KiBV1,
abi.RegisteredSealProof_StackedDrg512MiBV1, // <==
abi.RegisteredSealProof_StackedDrg512MiBV1, // <== here
)
t.Cleanup(func() { // reset when done.
policy.SetSupportedProofTypes(
abi.RegisteredSealProof_StackedDrg2KiBV1,
)
})
}