Skip to content

Commit

Permalink
chore(e2e): v14.x protorev genesis (#4343)
Browse files Browse the repository at this point in the history
  • Loading branch information
p0mvn authored Feb 16, 2023
1 parent 0a4b5be commit 937d601
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions tests/e2e/initialization/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,19 @@ const (
OsmoIBCDenom = "ibc/ED07A3391A112B175915CD8FAF43A2DA8E4790EDE12566649D0C2F97716B8518"
StakeIBCDenom = "ibc/C053D637CCA2A2BA030E2C5EE1B28A16F71CCB0E45E8BE52766DC1B241B7787"
E2EFeeToken = "e2e-default-feetoken"
UstIBCDenom = "ibc/BE1BB42D4BE3C30D50B68D7C41DB4DFCE9678E8EF8C539F6E6A9345048894FCC"
LuncIBCDenom = "ibc/0EF15DF2F02480ADE0BB6E85D9EBB5DAEA2836D3860E9F97F9AADE4F57A31AA0"
MinGasPrice = "0.000"
IbcSendAmount = 3300000000
ValidatorWalletName = "val"
// chainA
ChainAID = "osmo-test-a"
OsmoBalanceA = 200000000000
OsmoBalanceA = 20000000000000
IonBalanceA = 100000000000
StakeBalanceA = 110000000000
StakeAmountA = 100000000000
UstBalanceA = 500000000000000
LuncBalanceA = 500000000000000
// chainB
ChainBID = "osmo-test-b"
OsmoBalanceB = 500000000000
Expand All @@ -73,8 +77,9 @@ const (
GenesisFeeBalance = 100000000000
WalletFeeBalance = 100000000

EpochDuration = time.Second * 60
TWAPPruningKeepPeriod = EpochDuration / 4
EpochDayDuration = time.Second * 60
EpochWeekDuration = time.Second * 120
TWAPPruningKeepPeriod = EpochDayDuration / 4
)

var (
Expand All @@ -83,7 +88,7 @@ var (
StakeAmountIntB = sdk.NewInt(StakeAmountB)
StakeAmountCoinB = sdk.NewCoin(OsmoDenom, StakeAmountIntB)

InitBalanceStrA = fmt.Sprintf("%d%s,%d%s,%d%s", OsmoBalanceA, OsmoDenom, StakeBalanceA, StakeDenom, IonBalanceA, IonDenom)
InitBalanceStrA = fmt.Sprintf("%d%s,%d%s,%d%s,%d%s,%d%s", OsmoBalanceA, OsmoDenom, StakeBalanceA, StakeDenom, IonBalanceA, IonDenom, UstBalanceA, UstIBCDenom, LuncBalanceA, LuncIBCDenom)
InitBalanceStrB = fmt.Sprintf("%d%s,%d%s,%d%s", OsmoBalanceB, OsmoDenom, StakeBalanceB, StakeDenom, IonBalanceB, IonDenom)
OsmoToken = sdk.NewInt64Coin(OsmoDenom, IbcSendAmount) // 3,300uosmo
StakeToken = sdk.NewInt64Coin(StakeDenom, IbcSendAmount) // 3,300ustake
Expand Down Expand Up @@ -302,7 +307,7 @@ func initGenesis(chain *internalChain, votingPeriod, expeditedVotingPeriod time.
}

func updateBankGenesis(bankGenState *banktypes.GenesisState) {
denomsToRegister := []string{StakeDenom, IonDenom, OsmoDenom, AtomDenom}
denomsToRegister := []string{StakeDenom, IonDenom, OsmoDenom, AtomDenom, LuncIBCDenom, UstIBCDenom}
for _, denom := range denomsToRegister {
setDenomMetadata(bankGenState, denom)
}
Expand Down Expand Up @@ -382,7 +387,8 @@ func updateGammGenesis(gammGenState *gammtypes.GenesisState) {

func updateEpochGenesis(epochGenState *epochtypes.GenesisState) {
epochGenState.Epochs = []epochtypes.EpochInfo{
epochtypes.NewGenesisEpochInfo("week", time.Hour*24*7),
// override week epochs which are in default integrations, to be 2min
epochtypes.NewGenesisEpochInfo("week", time.Second*120),
// override day epochs which are in default integrations, to be 1min
epochtypes.NewGenesisEpochInfo("day", time.Second*60),
}
Expand Down

0 comments on commit 937d601

Please sign in to comment.