mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-12-25 15:55:18 +00:00
23 lines
553 B
Go
23 lines
553 B
Go
package e2e_test
|
|
|
|
import (
|
|
"math/big"
|
|
|
|
sdk "github.com/cosmos/cosmos-sdk/types"
|
|
)
|
|
|
|
func (suite *IntegrationTestSuite) TestGrpcClientUtil_Account() {
|
|
// ARRANGE
|
|
// setup 0g account
|
|
zgChainAcc := suite.ZgChain.NewFundedAccount("account-test", sdk.NewCoins(a0gi(big.NewInt(1e5))))
|
|
|
|
// ACT
|
|
rsp, err := suite.ZgChain.Grpc.BaseAccount(zgChainAcc.SdkAddress.String())
|
|
|
|
// ASSERT
|
|
suite.Require().NoError(err)
|
|
suite.Equal(zgChainAcc.SdkAddress.String(), rsp.Address)
|
|
suite.Greater(rsp.AccountNumber, uint64(1))
|
|
suite.Equal(uint64(0), rsp.Sequence)
|
|
}
|