From cf9aa20f4c2b922cc1539f4717e3ad0e13e66c5b Mon Sep 17 00:00:00 2001 From: yivlad Date: Thu, 25 Apr 2024 11:06:00 +0200 Subject: [PATCH 1/4] Take borrow cap into account in validateBorrow and getBorrowMaxValue --- .../getBorrowMaxValue.test.ts | 27 ++++- .../getBorrowMaxValue.ts | 10 +- .../market-validators/validateBorrow.test.ts | 103 ++++++++++++++++++ .../market-validators/validateBorrow.ts | 15 ++- 4 files changed, 149 insertions(+), 6 deletions(-) diff --git a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts index aacddcf4c..575aa83fd 100644 --- a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts +++ b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts @@ -8,6 +8,7 @@ describe(getBorrowMaxValue.name, () => { getBorrowMaxValue({ asset: { availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(0), }, user: { maxBorrowBasedOnCollateral: NormalizedUnitNumber(0), @@ -21,6 +22,7 @@ describe(getBorrowMaxValue.name, () => { getBorrowMaxValue({ asset: { availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(0), }, user: { maxBorrowBasedOnCollateral: NormalizedUnitNumber(100), @@ -28,6 +30,21 @@ describe(getBorrowMaxValue.name, () => { }), ).toEqual(NormalizedUnitNumber(100)) }) + + it('returns borrow cap based borrow limit', () => { + expect( + getBorrowMaxValue({ + asset: { + availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(50), + borrowCap: NormalizedUnitNumber(100), + }, + user: { + maxBorrowBasedOnCollateral: NormalizedUnitNumber(Infinity), + }, + }), + ).toEqual(NormalizedUnitNumber(50)) + }) }) describe('limited liquidity', () => { @@ -36,6 +53,7 @@ describe(getBorrowMaxValue.name, () => { getBorrowMaxValue({ asset: { availableLiquidity: NormalizedUnitNumber(10), + totalDebt: NormalizedUnitNumber(0), }, user: { maxBorrowBasedOnCollateral: NormalizedUnitNumber(0), @@ -44,17 +62,18 @@ describe(getBorrowMaxValue.name, () => { ).toEqual(NormalizedUnitNumber(0)) }) - it('returns available liquidity value when smaller than borrow limit', () => { + it('returns available liquidity based value when smaller than borrow limit', () => { expect( getBorrowMaxValue({ asset: { availableLiquidity: NormalizedUnitNumber(10), + totalDebt: NormalizedUnitNumber(5), }, user: { maxBorrowBasedOnCollateral: NormalizedUnitNumber(100), }, }), - ).toEqual(NormalizedUnitNumber(10)) + ).toEqual(NormalizedUnitNumber(5)) }) }) @@ -70,6 +89,7 @@ describe(getBorrowMaxValue.name, () => { }, asset: { availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(0), }, }), ).toEqual(NormalizedUnitNumber(0)) @@ -86,6 +106,7 @@ describe(getBorrowMaxValue.name, () => { }, asset: { availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(0), }, }), ).toEqual(NormalizedUnitNumber(100)) @@ -103,6 +124,7 @@ describe(getBorrowMaxValue.name, () => { asset: { availableLiquidity: NormalizedUnitNumber(Infinity), + totalDebt: NormalizedUnitNumber(0), }, }), ).toEqual(NormalizedUnitNumber(50)) @@ -116,6 +138,7 @@ describe(getBorrowMaxValue.name, () => { }, asset: { availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), }, } diff --git a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts index 7b423570e..9da60f4d5 100644 --- a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts +++ b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts @@ -5,6 +5,8 @@ import { NormalizedUnitNumber } from '../types/NumericValues' interface GetBorrowMaxValueParams { asset: { availableLiquidity: NormalizedUnitNumber + totalDebt: NormalizedUnitNumber + borrowCap?: NormalizedUnitNumber } user: { maxBorrowBasedOnCollateral: NormalizedUnitNumber @@ -26,13 +28,15 @@ export function getBorrowMaxValue({ asset, user, validationIssue }: GetBorrowMax ) { return NormalizedUnitNumber(0) } - - const ceilings = [asset.availableLiquidity, user.maxBorrowBasedOnCollateral] + const ceilings = [asset.availableLiquidity, asset.borrowCap] + .filter(Boolean) + .map((value) => value.minus(asset.totalDebt)) + ceilings.push(user.maxBorrowBasedOnCollateral) const { inIsolationMode, isolationModeCollateralTotalDebt, isolationModeCollateralDebtCeiling } = user if (inIsolationMode && isolationModeCollateralTotalDebt && isolationModeCollateralDebtCeiling) { ceilings.push(NormalizedUnitNumber(isolationModeCollateralDebtCeiling.minus(isolationModeCollateralTotalDebt))) } - return NormalizedUnitNumber(BigNumber.min(...ceilings)) + return NormalizedUnitNumber(BigNumber.max(BigNumber.min(...ceilings), 0)) } diff --git a/packages/app/src/domain/market-validators/validateBorrow.test.ts b/packages/app/src/domain/market-validators/validateBorrow.test.ts index e940c8e31..4288137d4 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.test.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.test.ts @@ -13,6 +13,7 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -37,6 +38,8 @@ describe(validateBorrow.name, () => { status: 'frozen', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -61,6 +64,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: false, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -85,6 +90,34 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + + isSiloed: false, + borrowableInIsolation: false, + eModeCategory: 0, + }, + user: { + maxBorrowBasedOnCollateral: NormalizedUnitNumber(200), + totalBorrowedUSD: NormalizedUnitNumber(0), + isInSiloMode: false, + inIsolationMode: false, + eModeCategory: 0, + }, + }), + ).toStrictEqual('exceeds-liquidity') + }) + + it('takes into account total debt when validating liquidity', () => { + expect( + validateBorrow({ + value: NormalizedUnitNumber(98), + asset: { + address: testAddresses.token, + status: 'active', + borrowingEnabled: true, + availableLiquidity: NormalizedUnitNumber(102), + totalDebt: NormalizedUnitNumber(5), + isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -100,6 +133,60 @@ describe(validateBorrow.name, () => { ).toStrictEqual('exceeds-liquidity') }) + it('validates borrow cap', () => { + expect( + validateBorrow({ + value: NormalizedUnitNumber(101), + asset: { + address: testAddresses.token, + status: 'active', + borrowingEnabled: true, + availableLiquidity: NormalizedUnitNumber(102), + borrowCap: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + + isSiloed: false, + borrowableInIsolation: false, + eModeCategory: 0, + }, + user: { + maxBorrowBasedOnCollateral: NormalizedUnitNumber(200), + totalBorrowedUSD: NormalizedUnitNumber(0), + isInSiloMode: false, + inIsolationMode: false, + eModeCategory: 0, + }, + }), + ).toStrictEqual('borrow-cap-reached') + }) + + it('takes into account total debt when validating borrow cap', () => { + expect( + validateBorrow({ + value: NormalizedUnitNumber(96), + asset: { + address: testAddresses.token, + status: 'active', + borrowingEnabled: true, + availableLiquidity: NormalizedUnitNumber(102), + borrowCap: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(5), + + isSiloed: false, + borrowableInIsolation: false, + eModeCategory: 0, + }, + user: { + maxBorrowBasedOnCollateral: NormalizedUnitNumber(200), + totalBorrowedUSD: NormalizedUnitNumber(0), + isInSiloMode: false, + inIsolationMode: false, + eModeCategory: 0, + }, + }), + ).toStrictEqual('borrow-cap-reached') + }) + it('validates collateralization', () => { expect( validateBorrow({ @@ -109,6 +196,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(101), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -133,6 +222,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: true, borrowableInIsolation: false, eModeCategory: 0, @@ -157,6 +248,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: true, borrowableInIsolation: false, eModeCategory: 0, @@ -183,6 +276,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -210,6 +305,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: true, eModeCategory: 0, @@ -236,6 +333,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: true, eModeCategory: 0, @@ -264,6 +363,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: true, eModeCategory: 1, @@ -290,6 +391,8 @@ describe(validateBorrow.name, () => { status: 'active', borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), + totalDebt: NormalizedUnitNumber(0), + isSiloed: false, borrowableInIsolation: true, eModeCategory: 2, diff --git a/packages/app/src/domain/market-validators/validateBorrow.ts b/packages/app/src/domain/market-validators/validateBorrow.ts index ab844c0dc..7a1440c38 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.ts @@ -14,6 +14,8 @@ export interface ValidateBorrowParams { status: ReserveStatus borrowingEnabled: boolean availableLiquidity: NormalizedUnitNumber + totalDebt: NormalizedUnitNumber + borrowCap?: NormalizedUnitNumber isSiloed: boolean borrowableInIsolation: boolean eModeCategory: number @@ -36,6 +38,7 @@ export type BorrowValidationIssue = | 'reserve-not-active' | 'reserve-borrowing-disabled' | 'exceeds-liquidity' + | 'borrow-cap-reached' | 'insufficient-collateral' | 'siloed-mode-cannot-enable' | 'siloed-mode-enabled' @@ -50,6 +53,8 @@ export function validateBorrow({ status, borrowingEnabled, availableLiquidity, + totalDebt, + borrowCap, isSiloed, borrowableInIsolation, eModeCategory: assetEModeCategory, @@ -66,6 +71,7 @@ export function validateBorrow({ }, }: ValidateBorrowParams): BorrowValidationIssue | undefined { const borrowedAnythingBefore = !totalBorrowedUSD.isEqualTo(0) + const totalDebtAfterBorrow = totalDebt.plus(value) if (value.isLessThanOrEqualTo(0)) { return 'value-not-positive' @@ -79,10 +85,14 @@ export function validateBorrow({ return 'reserve-borrowing-disabled' } - if (availableLiquidity.lt(value)) { + if (availableLiquidity.lt(totalDebtAfterBorrow)) { return 'exceeds-liquidity' } + if (borrowCap?.lt(totalDebtAfterBorrow)) { + return 'borrow-cap-reached' + } + if (value.gt(maxBorrowBasedOnCollateral)) { return 'insufficient-collateral' } @@ -122,6 +132,7 @@ export function validateBorrow({ export const borrowValidationIssueToMessage: Record = { 'value-not-positive': 'Borrow value should be positive', 'exceeds-liquidity': 'Borrow value exceeds liquidity', + 'borrow-cap-reached': 'Borrow cap reached', 'insufficient-collateral': 'Not enough collateral to borrow this amount', 'siloed-mode-enabled': 'Siloed borrowing enabled. Borrowing other assets is not allowed.', 'siloed-mode-cannot-enable': @@ -148,6 +159,8 @@ export function getValidateBorrowArgs( status: reserve.status, borrowingEnabled: reserve.borrowEligibilityStatus !== 'no', availableLiquidity: reserve.availableLiquidity, + totalDebt: reserve.totalDebt, + borrowCap: reserve.borrowCap, isSiloed: reserve.isSiloedBorrowing, borrowableInIsolation: reserve.isBorrowableInIsolation, eModeCategory: reserve.eModeCategory?.id ?? 0, From 7d471c426417c00ab25e246573d227b7a348eab5 Mon Sep 17 00:00:00 2001 From: yivlad Date: Thu, 25 Apr 2024 11:08:05 +0200 Subject: [PATCH 2/4] Remove unnecessary empty lines --- .../domain/market-validators/validateBorrow.test.ts | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/packages/app/src/domain/market-validators/validateBorrow.test.ts b/packages/app/src/domain/market-validators/validateBorrow.test.ts index 4288137d4..6a2a67481 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.test.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.test.ts @@ -65,7 +65,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: false, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -91,7 +90,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -117,7 +115,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(102), totalDebt: NormalizedUnitNumber(5), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -144,7 +141,6 @@ describe(validateBorrow.name, () => { availableLiquidity: NormalizedUnitNumber(102), borrowCap: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -171,7 +167,6 @@ describe(validateBorrow.name, () => { availableLiquidity: NormalizedUnitNumber(102), borrowCap: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(5), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -197,7 +192,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(101), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -223,7 +217,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: true, borrowableInIsolation: false, eModeCategory: 0, @@ -249,7 +242,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: true, borrowableInIsolation: false, eModeCategory: 0, @@ -277,7 +269,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0, @@ -306,7 +297,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: true, eModeCategory: 0, @@ -334,7 +324,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: true, eModeCategory: 0, @@ -364,7 +353,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: true, eModeCategory: 1, @@ -392,7 +380,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: true, eModeCategory: 2, From ac7925b24c0828844bb64511627c16aed054cd4a Mon Sep 17 00:00:00 2001 From: yivlad Date: Thu, 25 Apr 2024 11:25:34 +0200 Subject: [PATCH 3/4] Fix liquidity issue --- .../getBorrowMaxValue.test.ts | 2 +- .../getBorrowMaxValue.ts | 10 +++++--- .../market-validators/validateBorrow.test.ts | 25 ------------------- .../market-validators/validateBorrow.ts | 5 ++-- 4 files changed, 9 insertions(+), 33 deletions(-) diff --git a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts index 575aa83fd..b6e7e352e 100644 --- a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts +++ b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.test.ts @@ -73,7 +73,7 @@ describe(getBorrowMaxValue.name, () => { maxBorrowBasedOnCollateral: NormalizedUnitNumber(100), }, }), - ).toEqual(NormalizedUnitNumber(5)) + ).toEqual(NormalizedUnitNumber(10)) }) }) diff --git a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts index 9da60f4d5..760b741c4 100644 --- a/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts +++ b/packages/app/src/domain/action-max-value-getters/getBorrowMaxValue.ts @@ -28,10 +28,12 @@ export function getBorrowMaxValue({ asset, user, validationIssue }: GetBorrowMax ) { return NormalizedUnitNumber(0) } - const ceilings = [asset.availableLiquidity, asset.borrowCap] - .filter(Boolean) - .map((value) => value.minus(asset.totalDebt)) - ceilings.push(user.maxBorrowBasedOnCollateral) + const ceilings = [asset.availableLiquidity, user.maxBorrowBasedOnCollateral] + + if (asset.borrowCap) { + ceilings.push(NormalizedUnitNumber(asset.borrowCap.minus(asset.totalDebt))) + } + const { inIsolationMode, isolationModeCollateralTotalDebt, isolationModeCollateralDebtCeiling } = user if (inIsolationMode && isolationModeCollateralTotalDebt && isolationModeCollateralDebtCeiling) { diff --git a/packages/app/src/domain/market-validators/validateBorrow.test.ts b/packages/app/src/domain/market-validators/validateBorrow.test.ts index 6a2a67481..3b82685e2 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.test.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.test.ts @@ -105,31 +105,6 @@ describe(validateBorrow.name, () => { ).toStrictEqual('exceeds-liquidity') }) - it('takes into account total debt when validating liquidity', () => { - expect( - validateBorrow({ - value: NormalizedUnitNumber(98), - asset: { - address: testAddresses.token, - status: 'active', - borrowingEnabled: true, - availableLiquidity: NormalizedUnitNumber(102), - totalDebt: NormalizedUnitNumber(5), - isSiloed: false, - borrowableInIsolation: false, - eModeCategory: 0, - }, - user: { - maxBorrowBasedOnCollateral: NormalizedUnitNumber(200), - totalBorrowedUSD: NormalizedUnitNumber(0), - isInSiloMode: false, - inIsolationMode: false, - eModeCategory: 0, - }, - }), - ).toStrictEqual('exceeds-liquidity') - }) - it('validates borrow cap', () => { expect( validateBorrow({ diff --git a/packages/app/src/domain/market-validators/validateBorrow.ts b/packages/app/src/domain/market-validators/validateBorrow.ts index 7a1440c38..3d59ae007 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.ts @@ -71,7 +71,6 @@ export function validateBorrow({ }, }: ValidateBorrowParams): BorrowValidationIssue | undefined { const borrowedAnythingBefore = !totalBorrowedUSD.isEqualTo(0) - const totalDebtAfterBorrow = totalDebt.plus(value) if (value.isLessThanOrEqualTo(0)) { return 'value-not-positive' @@ -85,11 +84,11 @@ export function validateBorrow({ return 'reserve-borrowing-disabled' } - if (availableLiquidity.lt(totalDebtAfterBorrow)) { + if (availableLiquidity.lt(value)) { return 'exceeds-liquidity' } - if (borrowCap?.lt(totalDebtAfterBorrow)) { + if (borrowCap?.lt(totalDebt.plus(value))) { return 'borrow-cap-reached' } From 17a8442029fdc3691d38b9c9df85b0dcc0690e8b Mon Sep 17 00:00:00 2001 From: yivlad Date: Thu, 25 Apr 2024 12:08:49 +0200 Subject: [PATCH 4/4] Remove empty line --- packages/app/src/domain/market-validators/validateBorrow.test.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/app/src/domain/market-validators/validateBorrow.test.ts b/packages/app/src/domain/market-validators/validateBorrow.test.ts index 3b82685e2..5b59148de 100644 --- a/packages/app/src/domain/market-validators/validateBorrow.test.ts +++ b/packages/app/src/domain/market-validators/validateBorrow.test.ts @@ -39,7 +39,6 @@ describe(validateBorrow.name, () => { borrowingEnabled: true, availableLiquidity: NormalizedUnitNumber(100), totalDebt: NormalizedUnitNumber(0), - isSiloed: false, borrowableInIsolation: false, eModeCategory: 0,