Skip to content

Commit 97df72b

Browse files
committed
test: remove extra loop from advance epochs helper
1 parent 3e0b6bd commit 97df72b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

test/lib/testHelpers.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export const advanceToNextEpoch = async (epochManager: EpochManager): Promise<vo
8484
}
8585

8686
export const advanceEpochs = async (epochManager: EpochManager, n: number): Promise<void> => {
87-
for (let i = 0; i < n + 1; i++) {
87+
for (let i = 0; i < n; i++) {
8888
await advanceToNextEpoch(epochManager)
8989
}
9090
}

test/staking/allocation.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -696,7 +696,7 @@ describe('Staking:Allocation', () => {
696696

697697
// Move max allocation epochs to close by delegator
698698
const maxAllocationEpochs = await staking.maxAllocationEpochs()
699-
await advanceEpochs(epochManager, maxAllocationEpochs)
699+
await advanceEpochs(epochManager, maxAllocationEpochs + 1)
700700

701701
// Closing should only be possible if allocated tokens > 0
702702
const alloc = await staking.getAllocation(allocationID)

0 commit comments

Comments
 (0)