Skip to content

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
envestcc committed Oct 10, 2023
1 parent a3dc2dc commit fbb4680
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions e2etest/contract_staking_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1259,6 +1259,7 @@ var (
common.BytesToAddress(identityset.Address(4).Bytes()),
common.BytesToAddress(identityset.Address(5).Bytes()),
common.BytesToAddress(identityset.Address(6).Bytes()),
common.BytesToAddress(identityset.Address(7).Bytes()),
}
)

Expand Down Expand Up @@ -1875,11 +1876,11 @@ func TestContractStaking(t *testing.T) {
t.Run("afterRedsea", func(t *testing.T) {
jumpBlocks(bc, _testRedseaBlockHeight, r)
t.Run("weightedVotes", func(t *testing.T) {
simpleStake(_delegates[6], big.NewInt(100), big.NewInt(100))
simpleStake(_delegates[7], big.NewInt(100), big.NewInt(100))
height, err := indexer.Height()
r.NoError(err)
ctx := protocol.WithFeatureCtx(protocol.WithBlockCtx(ctx, protocol.BlockCtx{BlockHeight: height}))
votes, err := indexer.CandidateVotes(ctx, identityset.Address(6), height)
votes, err := indexer.CandidateVotes(ctx, identityset.Address(7), height)
r.NoError(err)
r.EqualValues(103, votes.Int64())
})
Expand Down

0 comments on commit fbb4680

Please sign in to comment.