@@ -14,7 +14,6 @@ import (
1414 "github.com/osmosis-labs/osmosis/osmomath"
1515 "github.com/osmosis-labs/osmosis/v24/app/apptesting"
1616
17- v23 "github.com/osmosis-labs/osmosis/v24/app/upgrades/v23"
1817 concentratedtypes "github.com/osmosis-labs/osmosis/v24/x/concentrated-liquidity/types"
1918)
2019
@@ -88,29 +87,27 @@ func (s *UpgradeTestSuite) TestUpgrade() {
8887 s .Require ().NotEmpty (nonMigratedPoolBeforeUpgradeIncentives )
8988
9089 // Overwrite the migration list with the desired pool ID.
91- oldMigrationList := v23 .MigratedIncentiveAccumulatorPoolIDs
92- v23 .MigratedIncentiveAccumulatorPoolIDs = map [uint64 ]struct {}{}
93- v23 .MigratedIncentiveAccumulatorPoolIDs [lastPoolID ] = struct {}{}
90+ oldMigrationList := concentratedtypes .MigratedIncentiveAccumulatorPoolIDs
91+ concentratedtypes .MigratedIncentiveAccumulatorPoolIDs = map [uint64 ]struct {}{}
92+ concentratedtypes .MigratedIncentiveAccumulatorPoolIDs [lastPoolID ] = struct {}{}
9493
9594 dummyUpgrade (s )
9695 s .Require ().NotPanics (func () {
9796 s .App .BeginBlocker (s .Ctx , abci.RequestBeginBlock {})
9897 })
9998
100- // NOTE: these no longer work as expected in versions later than v23, in v23 we decide between the old and new scaling factor.
101- // Since we're removing this choice, these test are not worrking as expected
10299 // Migrated pool: ensure that the claimable incentives are the same before and after migration
103- // migratedPoolAfterUpgradeIncentives, _, err := s.App.ConcentratedLiquidityKeeper.GetClaimableIncentives(s.Ctx, lastPoolPositionID)
104- // s.Require().NoError(err)
105- // s.Require().Equal(migratedPoolBeforeUpgradeIncentives.String(), migratedPoolAfterUpgradeIncentives.String())
100+ migratedPoolAfterUpgradeIncentives , _ , err := s .App .ConcentratedLiquidityKeeper .GetClaimableIncentives (s .Ctx , lastPoolPositionID )
101+ s .Require ().NoError (err )
102+ s .Require ().Equal (migratedPoolBeforeUpgradeIncentives .String (), migratedPoolAfterUpgradeIncentives .String ())
106103
107- //// Non-migrated pool: ensure that the claimable incentives are the same before and after migration
108- // nonMigratedPoolAfterUpgradeIncentives, _, err := s.App.ConcentratedLiquidityKeeper.GetClaimableIncentives(s.Ctx, lastPoolPositionID-1)
109- // s.Require().NoError(err)
110- // s.Require().Equal(nonMigratedPoolBeforeUpgradeIncentives.String(), nonMigratedPoolAfterUpgradeIncentives.String())
104+ // Non-migrated pool: ensure that the claimable incentives are the same before and after migration
105+ nonMigratedPoolAfterUpgradeIncentives , _ , err := s .App .ConcentratedLiquidityKeeper .GetClaimableIncentives (s .Ctx , lastPoolPositionID - 1 )
106+ s .Require ().NoError (err )
107+ s .Require ().Equal (nonMigratedPoolBeforeUpgradeIncentives .String (), nonMigratedPoolAfterUpgradeIncentives .String ())
111108
112109 // Restore the migration list for use by other tests
113- v23 .MigratedIncentiveAccumulatorPoolIDs = oldMigrationList
110+ concentratedtypes .MigratedIncentiveAccumulatorPoolIDs = oldMigrationList
114111}
115112
116113func dummyUpgrade (s * UpgradeTestSuite ) {
0 commit comments