Skip to content

Commit

Permalink
Restored a missing test (#9460)
Browse files Browse the repository at this point in the history
Authored-by: Nina Barbakadze <ninabarbakadze@macbook-pro-4.localdomain>
  • Loading branch information
ninabarbakadze authored and martinvol committed May 13, 2022
1 parent 0b51c65 commit 3cfceab
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion packages/protocol/test/governance/voting/lockedgold.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,13 +202,21 @@ contract('LockedGold', (accounts: string[]) => {
)
})

it('should add a pending withdrawal', async () => {
it('should add a pending withdrawal #getPendingWithdrawal()', async () => {
const [val, timestamp] = await lockedGold.getPendingWithdrawal(account, 0)
assertEqualBN(val, value)
assertEqualBN(timestamp, availabilityTime)
await assertRevert(lockedGold.getPendingWithdrawal(account, 1))
})

it('should add a pending withdrawal #getPendingWithdrawals()', async () => {
const [values, timestamps] = await lockedGold.getPendingWithdrawals(account)
assert.equal(values.length, 1)
assert.equal(timestamps.length, 1)
assertEqualBN(values[0], value)
assertEqualBN(timestamps[0], availabilityTime)
})

it("should decrease the account's nonvoting locked gold balance", async () => {
assertEqualBN(await lockedGold.getAccountNonvotingLockedGold(account), 0)
})
Expand Down

0 comments on commit 3cfceab

Please sign in to comment.