refactor!: abstractions for snapshot and pruning; snapshot intervals eventually pruned; unit tests (#11496)
This commit is contained in:
+4
-8
@@ -9,10 +9,6 @@ import (
|
||||
"github.com/cosmos/cosmos-sdk/types/kv"
|
||||
)
|
||||
|
||||
type (
|
||||
PruningOptions = types.PruningOptions
|
||||
)
|
||||
|
||||
type (
|
||||
Store = types.Store
|
||||
Committer = types.Committer
|
||||
@@ -155,15 +151,15 @@ type (
|
||||
GasConfig = types.GasConfig
|
||||
)
|
||||
|
||||
func NewGasMeter(limit Gas) GasMeter {
|
||||
return types.NewGasMeter(limit)
|
||||
}
|
||||
|
||||
type (
|
||||
ErrorOutOfGas = types.ErrorOutOfGas
|
||||
ErrorGasOverflow = types.ErrorGasOverflow
|
||||
)
|
||||
|
||||
func NewGasMeter(limit Gas) GasMeter {
|
||||
return types.NewGasMeter(limit)
|
||||
}
|
||||
|
||||
func NewInfiniteGasMeter() GasMeter {
|
||||
return types.NewInfiniteGasMeter()
|
||||
}
|
||||
|
||||
+2
-1
@@ -4,6 +4,7 @@ import (
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/suite"
|
||||
"github.com/tendermint/tendermint/libs/log"
|
||||
dbm "github.com/tendermint/tm-db"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/store/rootmulti"
|
||||
@@ -108,7 +109,7 @@ func (s *storeTestSuite) TestDiffKVStores() {
|
||||
|
||||
func (s *storeTestSuite) initTestStores() (types.KVStore, types.KVStore) {
|
||||
db := dbm.NewMemDB()
|
||||
ms := rootmulti.NewStore(db)
|
||||
ms := rootmulti.NewStore(db, log.NewNopLogger())
|
||||
|
||||
key1 := types.NewKVStoreKey("store1")
|
||||
key2 := types.NewKVStoreKey("store2")
|
||||
|
||||
Reference in New Issue
Block a user