Skip to content

Commit ddf3067

Browse files
committed
Revert "adjust test to work with new price bands"
This reverts commit ee40ac8.
1 parent ee40ac8 commit ddf3067

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

tests/liquidateBorrowForPerpPnl.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ describe('liquidate borrow for perp pnl', () => {
174174
new BN(0)
175175
);
176176

177-
await driftClient.moveAmmToPrice(0, PRICE_PRECISION.muln(120).divn(100));
177+
await driftClient.moveAmmToPrice(0, new BN(2).mul(PRICE_PRECISION));
178178

179179
await driftClient.closePosition(0);
180180

@@ -256,15 +256,14 @@ describe('liquidate borrow for perp pnl', () => {
256256
)
257257
);
258258
assert(liquidationRecord.liquidateBorrowForPerpPnl.perpMarketIndex === 0);
259-
260259
assert(
261260
liquidationRecord.liquidateBorrowForPerpPnl.pnlTransfer.gt(
262-
new BN(1977993 - 10)
261+
new BN(9969992 - 10)
263262
)
264263
);
265264
assert(
266265
liquidationRecord.liquidateBorrowForPerpPnl.pnlTransfer.lt(
267-
new BN(1977993 + 10)
266+
new BN(9969992 + 10)
268267
)
269268
);
270269
assert(
@@ -278,7 +277,7 @@ describe('liquidate borrow for perp pnl', () => {
278277

279278
assert(
280279
liquidationRecord.liquidateBorrowForPerpPnl.liabilityTransfer.eq(
281-
new BN(39559860)
280+
new BN(199399800)
282281
)
283282
);
284283
});

0 commit comments

Comments
 (0)