@@ -592,7 +592,7 @@ func (suite *StateDBTestSuite) TestIterateStorage() {
592592func (suite * StateDBTestSuite ) TestNativeAction () {
593593 _ , ctx , keeper := setupTestEnv (suite .T ())
594594 storeKey := testStoreKeys ["testnative" ]
595- transientKey := testTransientKeys [evmtypes .TransientKey ]
595+ objStoreKey := testObjKeys [evmtypes .ObjectStoreKey ]
596596 memKey := testMemKeys [capabilitytypes .MemStoreKey ]
597597
598598 eventConverter := func (event sdk.Event ) (* ethtypes.Log , error ) {
@@ -619,8 +619,8 @@ func (suite *StateDBTestSuite) TestNativeAction() {
619619 store .Set ([]byte ("success1" ), []byte ("value" ))
620620 ctx .EventManager ().EmitEvent (sdk .NewEvent ("success1" ))
621621
622- transient := ctx .KVStore ( transientKey )
623- transient .Set ([]byte ("transient" ), [] byte ( "value" ) )
622+ objStore := ctx .ObjectStore ( objStoreKey )
623+ objStore .Set ([]byte ("transient" ), "value" )
624624
625625 mem := ctx .KVStore (memKey )
626626 mem .Set ([]byte ("mem" ), []byte ("value" ))
@@ -632,8 +632,8 @@ func (suite *StateDBTestSuite) TestNativeAction() {
632632 store .Set ([]byte ("failure1" ), []byte ("value" ))
633633 ctx .EventManager ().EmitEvent (sdk .NewEvent ("failure1" ))
634634
635- transient := ctx .KVStore ( transientKey )
636- suite .Require ().Equal ([] byte ( "value" ), transient .Get ([]byte ("transient" )))
635+ objStore := ctx .ObjectStore ( objStoreKey )
636+ suite .Require ().Equal ("value" , objStore .Get ([]byte ("transient" )).( string ))
637637
638638 mem := ctx .KVStore (memKey )
639639 suite .Require ().Equal ([]byte ("value" ), mem .Get ([]byte ("mem" )))
@@ -771,10 +771,9 @@ func CollectContractStorage(db vm.StateDB, address common.Address) statedb.Stora
771771}
772772
773773var (
774- testStoreKeys = storetypes .NewKVStoreKeys (authtypes .StoreKey , banktypes .StoreKey , evmtypes .StoreKey , "testnative" )
775- testObjKeys = storetypes .NewObjectStoreKeys (banktypes .ObjectStoreKey )
776- testTransientKeys = storetypes .NewTransientStoreKeys (evmtypes .TransientKey )
777- testMemKeys = storetypes .NewMemoryStoreKeys (capabilitytypes .MemStoreKey )
774+ testStoreKeys = storetypes .NewKVStoreKeys (authtypes .StoreKey , banktypes .StoreKey , evmtypes .StoreKey , "testnative" )
775+ testObjKeys = storetypes .NewObjectStoreKeys (banktypes .ObjectStoreKey , evmtypes .ObjectStoreKey )
776+ testMemKeys = storetypes .NewMemoryStoreKeys (capabilitytypes .MemStoreKey )
778777)
779778
780779func cloneRawState (t * testing.T , cms storetypes.MultiStore ) map [string ]map [string ][]byte {
@@ -822,7 +821,7 @@ func newTestKeeper(t *testing.T, cms storetypes.MultiStore) (sdk.Context, *evmke
822821 evmKeeper := evmkeeper .NewKeeper (
823822 appCodec ,
824823 runtime .NewKVStoreService (testStoreKeys [evmtypes .StoreKey ]),
825- testStoreKeys [evmtypes .StoreKey ], testTransientKeys [evmtypes .TransientKey ], authtypes .NewModuleAddress (govtypes .ModuleName ),
824+ testStoreKeys [evmtypes .StoreKey ], testObjKeys [evmtypes .ObjectStoreKey ], authtypes .NewModuleAddress (govtypes .ModuleName ),
826825 accountKeeper , bankKeeper , nil , nil ,
827826 "" ,
828827 nil ,
@@ -838,9 +837,6 @@ func setupTestEnv(t *testing.T) (storetypes.MultiStore, sdk.Context, *evmkeeper.
838837 for _ , key := range testStoreKeys {
839838 cms .MountStoreWithDB (key , storetypes .StoreTypeIAVL , nil )
840839 }
841- for _ , key := range testTransientKeys {
842- cms .MountStoreWithDB (key , storetypes .StoreTypeTransient , nil )
843- }
844840 for _ , key := range testMemKeys {
845841 cms .MountStoreWithDB (key , storetypes .StoreTypeMemory , nil )
846842 }
0 commit comments