Skip to content
This repository was archived by the owner on Mar 1, 2024. It is now read-only.

Commit e954d58

Browse files
author
Denis Ermolin
committed
fix: migration of delegation test
1 parent ad041a9 commit e954d58

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

test/units/staking/stakeManager/StakeManager.test.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2500,8 +2500,8 @@ contract('StakeManager', async function(accounts) {
25002500
})
25012501
})
25022502

2503-
describe('when Chad migrates from non-matic validator', function() {
2504-
const aliceId = '9'
2503+
describe('when Chad migrates to foundation validator', function() {
2504+
const foundationNodeId = '2'
25052505
const bobId = '8'
25062506
const delegator = wallets[1].getChecksumAddressString()
25072507

@@ -2511,14 +2511,14 @@ contract('StakeManager', async function(accounts) {
25112511
await this.stakeToken.approve(this.stakeManager.address, delegationAmount, {
25122512
from: delegator
25132513
})
2514-
const aliceValidator = await this.stakeManager.validators(aliceId)
2515-
const aliceContract = await ValidatorShare.at(aliceValidator.contractAddress)
2516-
await buyVoucher(aliceContract, delegationAmount, delegator)
2514+
const nonFoundationValidator = await this.stakeManager.validators(bobId)
2515+
const nonFoundationContract = await ValidatorShare.at(nonFoundationValidator.contractAddress)
2516+
await buyVoucher(nonFoundationContract, delegationAmount, delegator)
25172517
})
25182518

25192519
it('Migration should fail', async function() {
25202520
await expectRevert(
2521-
this.stakeManager.migrateDelegation(aliceId, bobId, migrationAmount, { from: delegator }),
2521+
this.stakeManager.migrateDelegation(bobId, foundationNodeId, migrationAmount, { from: delegator }),
25222522
'Invalid migration')
25232523
})
25242524
})

0 commit comments

Comments
 (0)