diff --git a/x/epochs/keeper/hooks_test.go b/x/epochs/keeper/hooks_test.go index 156aad26..d6aa5f84 100644 --- a/x/epochs/keeper/hooks_test.go +++ b/x/epochs/keeper/hooks_test.go @@ -12,7 +12,7 @@ import ( type MockHooks struct{} const ( - EpochIdentifier = types.DayEpochId + EpochIdentifier = types.DailyEpochId BeforeEpochStartEventType = "BeforeEpochStart" AfterEpochEndEventType = "AfterEpochEnd" ) @@ -73,7 +73,7 @@ func (suite *KeeperTestSuite) TestAfterEpochHooks() { suite.app.EpochsKeeper.BeginBlocker(suite.ctx) // Check if curent epoch is expected - epochInfo, found := suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DayEpochId) + epochInfo, found := suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DailyEpochId) suite.Require().True(found) suite.Require().Equal(int64(2), epochInfo.CurrentEpoch) }, @@ -101,7 +101,7 @@ func (suite *KeeperTestSuite) TestAfterEpochHooks() { suite.app.EpochsKeeper.BeginBlocker(suite.ctx) // Check if curent epoch is expected - epochInfo, found := suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DayEpochId) + epochInfo, found := suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DailyEpochId) suite.Require().True(found) suite.Require().Equal(int64(2), epochInfo.CurrentEpoch) @@ -110,7 +110,7 @@ func (suite *KeeperTestSuite) TestAfterEpochHooks() { suite.app.EpochsKeeper.BeginBlocker(suite.ctx) // Check if curent epoch is expected - epochInfo, found = suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DayEpochId) + epochInfo, found = suite.app.EpochsKeeper.GetEpochInfo(suite.ctx, types.DailyEpochId) suite.Require().True(found) suite.Require().Equal(int64(3), epochInfo.CurrentEpoch) }, diff --git a/x/epochs/types/epoch_identifier.go b/x/epochs/types/epoch_identifier.go index 7a4ce0ab..80738b57 100644 --- a/x/epochs/types/epoch_identifier.go +++ b/x/epochs/types/epoch_identifier.go @@ -1,6 +1,6 @@ package types const ( - WeekEpochId = "week" - DayEpochId = "day" + WeeklyEpochId = "weekly" + DailyEpochId = "daily" ) diff --git a/x/epochs/types/epoch_info_test.go b/x/epochs/types/epoch_info_test.go index 70f3dbe6..fcd62c58 100644 --- a/x/epochs/types/epoch_info_test.go +++ b/x/epochs/types/epoch_info_test.go @@ -52,7 +52,7 @@ func (suite *EpochInfoTestSuite) TestValidateEpochInfo() { { ErrEpochDurationCannotBeZero, EpochInfo{ - IncentiveEpochId, + DailyEpochId, time.Now(), time.Hour * 0, 1, @@ -65,7 +65,7 @@ func (suite *EpochInfoTestSuite) TestValidateEpochInfo() { { ErrCurrentEpochCannotBeNegative, EpochInfo{ - IncentiveEpochId, + DailyEpochId, time.Now(), time.Hour * 24, -1, @@ -78,7 +78,7 @@ func (suite *EpochInfoTestSuite) TestValidateEpochInfo() { { ErrCurrentEpochStartHeightCannotBeNegative, EpochInfo{ - IncentiveEpochId, + DailyEpochId, time.Now(), time.Hour * 24, 1, @@ -91,7 +91,7 @@ func (suite *EpochInfoTestSuite) TestValidateEpochInfo() { { nil, EpochInfo{ - IncentiveEpochId, + DailyEpochId, time.Now(), time.Hour * 24, 1, diff --git a/x/epochs/types/genesis.go b/x/epochs/types/genesis.go index 48dd79ae..7c4c36b2 100644 --- a/x/epochs/types/genesis.go +++ b/x/epochs/types/genesis.go @@ -19,7 +19,7 @@ func DefaultGenesis() *GenesisState { return &GenesisState{ Epochs: []EpochInfo{ { - Identifier: WeekEpochId, + Identifier: WeeklyEpochId, StartTime: time.Time{}, Duration: time.Hour * 24 * 7, CurrentEpoch: 0, @@ -28,7 +28,7 @@ func DefaultGenesis() *GenesisState { EpochCountingStarted: false, }, { - Identifier: DayEpochId, + Identifier: DailyEpochId, StartTime: time.Time{}, Duration: time.Hour * 24, CurrentEpoch: 0, diff --git a/x/epochs/types/genesis_test.go b/x/epochs/types/genesis_test.go index 99556b3c..be5074ae 100644 --- a/x/epochs/types/genesis_test.go +++ b/x/epochs/types/genesis_test.go @@ -38,7 +38,7 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { &GenesisState{ Epochs: []EpochInfo{ { - Identifier: IncentiveEpochId, + Identifier: DailyEpochId, StartTime: time.Time{}, Duration: time.Hour * 24 * 7, CurrentEpoch: 0, @@ -55,7 +55,7 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { &GenesisState{ Epochs: []EpochInfo{ { - Identifier: IncentiveEpochId, + Identifier: DailyEpochId, StartTime: time.Time{}, Duration: time.Hour * 24 * 7, CurrentEpoch: 0, @@ -64,7 +64,7 @@ func (suite *GenesisTestSuite) TestValidateGenesis() { EpochCountingStarted: false, }, { - Identifier: IncentiveEpochId, + Identifier: DailyEpochId, StartTime: time.Time{}, Duration: time.Hour * 24 * 7, CurrentEpoch: 0,