From 1c26255956bb1fcb59839b5eb5764025fd688f4b Mon Sep 17 00:00:00 2001 From: Oliver He Date: Wed, 18 Oct 2023 18:26:25 -0400 Subject: [PATCH 1/2] Update staking.test.ts --- tests/e2e/api/staking.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/e2e/api/staking.test.ts b/tests/e2e/api/staking.test.ts index d3e75be33..30b79e336 100644 --- a/tests/e2e/api/staking.test.ts +++ b/tests/e2e/api/staking.test.ts @@ -12,7 +12,7 @@ describe("staking api", () => { }); expect(numDelegatorsData.length).toBeGreaterThan(5); for (let i = 1; i <= 5; i += 1) { - expect(numDelegatorsData[i].num_active_delegator).toBeGreaterThan(numDelegatorsData[i + 1].num_active_delegator); + expect(numDelegatorsData[i].num_active_delegator).toBeGreaterThanOrEqual(numDelegatorsData[i + 1].num_active_delegator); } const numDelegators = await aptos.getNumberOfDelegators({ poolAddress: numDelegatorsData[0].pool_address! }); expect(numDelegators).toEqual(numDelegatorsData[0].num_active_delegator); From b8592181d41be177b5915d37d86abd21714b66ce Mon Sep 17 00:00:00 2001 From: Oliver Date: Wed, 18 Oct 2023 18:30:36 -0400 Subject: [PATCH 2/2] fmt --- tests/e2e/api/staking.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/e2e/api/staking.test.ts b/tests/e2e/api/staking.test.ts index 30b79e336..5c6026412 100644 --- a/tests/e2e/api/staking.test.ts +++ b/tests/e2e/api/staking.test.ts @@ -12,7 +12,9 @@ describe("staking api", () => { }); expect(numDelegatorsData.length).toBeGreaterThan(5); for (let i = 1; i <= 5; i += 1) { - expect(numDelegatorsData[i].num_active_delegator).toBeGreaterThanOrEqual(numDelegatorsData[i + 1].num_active_delegator); + expect(numDelegatorsData[i].num_active_delegator).toBeGreaterThanOrEqual( + numDelegatorsData[i + 1].num_active_delegator, + ); } const numDelegators = await aptos.getNumberOfDelegators({ poolAddress: numDelegatorsData[0].pool_address! }); expect(numDelegators).toEqual(numDelegatorsData[0].num_active_delegator);