diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 983c24a1..f0b78ac3 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -71,7 +71,7 @@ jobs: sleep 5s docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run generate-subgraph-types - - name: Run Isolated Pools integration integration tests + - name: Run Isolated Pools integration tests run: | docker exec -i subgraph-hardhat-node yarn workspace isolated-pools-subgraph run test:integration --bail diff --git a/subgraphs/isolated-pools/tests/integration/constants.ts b/subgraphs/isolated-pools/tests/integration/constants.ts index 962a5e26..17ab9b45 100644 --- a/subgraphs/isolated-pools/tests/integration/constants.ts +++ b/subgraphs/isolated-pools/tests/integration/constants.ts @@ -6,9 +6,9 @@ export const SYNC_DELAY = 2000; export const defaultMarkets = [ { - id: '0xb9beecd1a582768711de1ee7b0a1d582d9d72a6c', + id: '0x40918ba7f132e0acba2ce4de4c4baf9bd2d7d849', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x525c7063e7c20997baae9bda922159152d0e8417', __typename: 'Pool', }, badDebtMantissa: '0', @@ -16,65 +16,63 @@ export const defaultMarkets = [ cashMantissa: '10000000000000000000', collateralFactorMantissa: '700000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0xb82008565fdc7e44609fa118a4a681e92581e680', - name: 'Venus ANKR', + interestRateModelAddress: '0x8a93d247134d91e0de6f96547cb0204e5be8e5d8', + name: 'Venus BTCB', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vANKR', - underlyingAddress: '0x4c5859f0f772848b2d91f1d83e2fe57935348029', - underlyingName: 'MockANKR', - underlyingSymbol: 'MockANKR', - borrowCapMantissa: '3000000000000000000000000', + symbol: 'vBTCB', + underlyingAddress: '0x70e0ba845a1a0f2da3359c97e0285013525ffc49', + underlyingName: 'MockBTCB', + underlyingSymbol: 'MockBTCB', + borrowCapMantissa: '1000000000000000000000', accrualBlockNumber: 263, - blockTimestamp: 1701809550, + blockTimestamp: 1706290532, borrowIndexMantissa: '1000000000000000000', reserveFactorMantissa: '250000000000000000', - underlyingPriceCents: '159', + underlyingPriceCents: '0', underlyingDecimals: 18, - supplyCapMantissa: '3000000000000000000000000', + supplyCapMantissa: '1000000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '800000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x5fc748f1feb28d7b76fa1c6b07d8ba2d5535177c', + id: '0x5feaebfb4439f3516c74939a9d04e95afe82c4ae', pool: { - id: '0xe3011a37a904ab90c8881a99bd1f6e21401f1522', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', - borrowRateMantissa: '951293759', + borrowRateMantissa: '0', cashMantissa: '10000000000000000000', - collateralFactorMantissa: '600000000000000000', + collateralFactorMantissa: '700000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', - name: 'Venus BNX', + interestRateModelAddress: '0x8a93d247134d91e0de6f96547cb0204e5be8e5d8', + name: 'Venus USDD', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vBNX', - underlyingAddress: '0xf5059a5d33d5853360d16c683c16e67980206f36', - underlyingName: 'MockBNX', - underlyingSymbol: 'MockBNX', - borrowCapMantissa: '478980000000000000000000', - accrualBlockNumber: 255, - blockTimestamp: 1701809541, - borrowIndexMantissa: '1000000069444444407', - reserveFactorMantissa: '250000000000000000', + symbol: 'vUSDD', + underlyingAddress: '0xdbc43ba45381e02825b14322cddd15ec4b3164e6', + underlyingName: 'MockUSDD', + underlyingSymbol: 'MockUSDD', + borrowCapMantissa: '1698253000000000000000000', + accrualBlockNumber: 291, + blockTimestamp: 1706290560, + borrowIndexMantissa: '1000000000000000000', + reserveFactorMantissa: '100000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '932019000000000000000000', + supplyCapMantissa: '10601805000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '700000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0xf32d39ff9f6aa7a7a64d7a4f00a54826ef791a55', + id: '0x6f6f570f45833e249e27022648a26f4076f48f78', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', @@ -82,7 +80,7 @@ export const defaultMarkets = [ cashMantissa: '10000000000000000000', collateralFactorMantissa: '600000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', + interestRateModelAddress: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', name: 'Venus NFT', reservesMantissa: '0', supplyRateMantissa: '0', @@ -91,23 +89,22 @@ export const defaultMarkets = [ underlyingName: 'MockNFT', underlyingSymbol: 'MockNFT', borrowCapMantissa: '24654278679000000000000000000', - accrualBlockNumber: 275, - blockTimestamp: 1701809563, + accrualBlockNumber: 279, + blockTimestamp: 1706290548, borrowIndexMantissa: '1000000077054794479', reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, supplyCapMantissa: '84985800573000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '700000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x40918ba7f132e0acba2ce4de4c4baf9bd2d7d849', + id: '0x99dbe4aea58e518c50a1c04ae9b48c9f6354612f', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', @@ -115,7 +112,7 @@ export const defaultMarkets = [ cashMantissa: '10000000000000000000', collateralFactorMantissa: '700000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0xb82008565fdc7e44609fa118a4a681e92581e680', + interestRateModelAddress: '0x8a93d247134d91e0de6f96547cb0204e5be8e5d8', name: 'Venus MBOX', reservesMantissa: '0', supplyRateMantissa: '0', @@ -124,89 +121,86 @@ export const defaultMarkets = [ underlyingName: 'MockMBOX', underlyingSymbol: 'MockMBOX', borrowCapMantissa: '3184294000000000000000000', - accrualBlockNumber: 271, - blockTimestamp: 1701809559, + accrualBlockNumber: 275, + blockTimestamp: 1706290544, borrowIndexMantissa: '1000000000000000000', reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, supplyCapMantissa: '7000000000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '800000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x6f6f570f45833e249e27022648a26f4076f48f78', + id: '0xb0f05d25e41fbc2b52013099ed9616f1206ae21b', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', - borrowRateMantissa: '0', + borrowRateMantissa: '951293759', cashMantissa: '10000000000000000000', - collateralFactorMantissa: '700000000000000000', + collateralFactorMantissa: '600000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0xb82008565fdc7e44609fa118a4a681e92581e680', - name: 'Venus USDD', + interestRateModelAddress: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', + name: 'Venus stkBNB', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vUSDD', - underlyingAddress: '0xdbc43ba45381e02825b14322cddd15ec4b3164e6', - underlyingName: 'MockUSDD', - underlyingSymbol: 'MockUSDD', - borrowCapMantissa: '1698253000000000000000000', + symbol: 'vstkBNB', + underlyingAddress: '0x922d6956c99e12dfeb3224dea977d0939758a1fe', + underlyingName: 'MockstkBNB', + underlyingSymbol: 'MockstkBNB', + borrowCapMantissa: '324000000000000000000', accrualBlockNumber: 287, - blockTimestamp: 1701809575, - borrowIndexMantissa: '1000000000000000000', - reserveFactorMantissa: '100000000000000000', + blockTimestamp: 1706290556, + borrowIndexMantissa: '1000000080859969515', + reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '10601805000000000000000000', + supplyCapMantissa: '1963000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '800000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', + id: '0xb9beecd1a582768711de1ee7b0a1d582d9d72a6c', pool: { - id: '0xe3011a37a904ab90c8881a99bd1f6e21401f1522', + id: '0x525c7063e7c20997baae9bda922159152d0e8417', __typename: 'Pool', }, badDebtMantissa: '0', - borrowRateMantissa: '0', + borrowRateMantissa: '951293759', cashMantissa: '10000000000000000000', - collateralFactorMantissa: '700000000000000000', + collateralFactorMantissa: '600000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0xb82008565fdc7e44609fa118a4a681e92581e680', - name: 'Venus BTCB', + interestRateModelAddress: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', + name: 'Venus BNX', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vBTCB', - underlyingAddress: '0x70e0ba845a1a0f2da3359c97e0285013525ffc49', - underlyingName: 'MockBTCB', - underlyingSymbol: 'MockBTCB', - borrowCapMantissa: '1000000000000000000000', + symbol: 'vBNX', + underlyingAddress: '0xf5059a5d33d5853360d16c683c16e67980206f36', + underlyingName: 'MockBNX', + underlyingSymbol: 'MockBNX', + borrowCapMantissa: '478980000000000000000000', accrualBlockNumber: 259, - blockTimestamp: 1701809546, - borrowIndexMantissa: '1000000000000000000', + blockTimestamp: 1706290528, + borrowIndexMantissa: '1000000069444444407', reserveFactorMantissa: '250000000000000000', - underlyingPriceCents: '0', + underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '1000000000000000000000', + supplyCapMantissa: '932019000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '800000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x8a93d247134d91e0de6f96547cb0204e5be8e5d8', + id: '0xca8c8688914e0f7096c920146cd0ad85cd7ae8b9', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', @@ -214,32 +208,31 @@ export const defaultMarkets = [ cashMantissa: '10000000000000000000', collateralFactorMantissa: '600000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', - name: 'Venus ankrBNB', + interestRateModelAddress: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', + name: 'Venus RACA', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vankrBNB', - underlyingAddress: '0xb7278a61aa25c888815afc32ad3cc52ff24fe575', - underlyingName: 'MockankrBNB', - underlyingSymbol: 'MockankrBNB', - borrowCapMantissa: '100000000000000000000', - accrualBlockNumber: 267, - blockTimestamp: 1701809554, - borrowIndexMantissa: '1000000073249619443', + symbol: 'vRACA', + underlyingAddress: '0x1429859428c0abc9c2c47c8ee9fbaf82cfa0f20f', + underlyingName: 'MockRACA', + underlyingSymbol: 'MockRACA', + borrowCapMantissa: '3805812642000000000000000000', + accrualBlockNumber: 283, + blockTimestamp: 1706290552, + borrowIndexMantissa: '1000000078957381997', reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '100000000000000000000', + supplyCapMantissa: '23758811062000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '700000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0x99dbe4aea58e518c50a1c04ae9b48c9f6354612f', + id: '0xd6e1afe5ca8d00a2efc01b89997abe2de47fdfaf', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', @@ -247,57 +240,55 @@ export const defaultMarkets = [ cashMantissa: '10000000000000000000', collateralFactorMantissa: '600000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', - name: 'Venus stkBNB', + interestRateModelAddress: '0x2a810409872afc346f9b5b26571fd6ec42ea4849', + name: 'Venus ankrBNB', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vstkBNB', - underlyingAddress: '0x922d6956c99e12dfeb3224dea977d0939758a1fe', - underlyingName: 'MockstkBNB', - underlyingSymbol: 'MockstkBNB', - borrowCapMantissa: '324000000000000000000', - accrualBlockNumber: 283, - blockTimestamp: 1701809571, - borrowIndexMantissa: '1000000080859969515', + symbol: 'vankrBNB', + underlyingAddress: '0xb7278a61aa25c888815afc32ad3cc52ff24fe575', + underlyingName: 'MockankrBNB', + underlyingSymbol: 'MockankrBNB', + borrowCapMantissa: '100000000000000000000', + accrualBlockNumber: 271, + blockTimestamp: 1706290540, + borrowIndexMantissa: '1000000073249619443', reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '1963000000000000000000', + supplyCapMantissa: '100000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '700000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', }, { - id: '0xd6e1afe5ca8d00a2efc01b89997abe2de47fdfaf', + id: '0xf32d39ff9f6aa7a7a64d7a4f00a54826ef791a55', pool: { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', __typename: 'Pool', }, badDebtMantissa: '0', - borrowRateMantissa: '951293759', + borrowRateMantissa: '0', cashMantissa: '10000000000000000000', - collateralFactorMantissa: '600000000000000000', + collateralFactorMantissa: '700000000000000000', exchangeRateMantissa: '10000000000000000000000000000', - interestRateModelAddress: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', - name: 'Venus RACA', + interestRateModelAddress: '0x8a93d247134d91e0de6f96547cb0204e5be8e5d8', + name: 'Venus ANKR', reservesMantissa: '0', supplyRateMantissa: '0', - symbol: 'vRACA', - underlyingAddress: '0x1429859428c0abc9c2c47c8ee9fbaf82cfa0f20f', - underlyingName: 'MockRACA', - underlyingSymbol: 'MockRACA', - borrowCapMantissa: '3805812642000000000000000000', - accrualBlockNumber: 279, - blockTimestamp: 1701809567, - borrowIndexMantissa: '1000000078957381997', + symbol: 'vANKR', + underlyingAddress: '0x4c5859f0f772848b2d91f1d83e2fe57935348029', + underlyingName: 'MockANKR', + underlyingSymbol: 'MockANKR', + borrowCapMantissa: '3000000000000000000000000', + accrualBlockNumber: 267, + blockTimestamp: 1706290536, + borrowIndexMantissa: '1000000000000000000', reserveFactorMantissa: '250000000000000000', underlyingPriceCents: '159', underlyingDecimals: 18, - supplyCapMantissa: '23758811062000000000000000000', + supplyCapMantissa: '3000000000000000000000000', accessControlManagerAddress: null, - liquidationThresholdMantissa: '700000000000000000', supplierCount: '1', borrowerCount: '0', __typename: 'Market', @@ -306,35 +297,35 @@ export const defaultMarkets = [ export const defaultPools = [ { - id: '0xe3011a37a904ab90c8881a99bd1f6e21401f1522', - name: 'Pool 1', + id: '0x38a024c0b412b9d1db8bc398140d00f5af3093d4', + name: 'Pool 2', creator: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', - blockPosted: '238', - timestampPosted: '1694787800', + blockPosted: '255', + timestampPosted: '1706291642', category: '', logoUrl: '', description: '', priceOracleAddress: '0x322813fd9a801c5507c9de605d63cea4f2ce6c44', - closeFactorMantissa: '50000000000000000', - liquidationIncentiveMantissa: '1000000000000000000', - minLiquidatableCollateralMantissa: '100000000000000000000', - markets: [Array], + closeFactorMantissa: '600000000000000000', + liquidationIncentiveMantissa: '3000000000000000000', + minLiquidatableCollateralMantissa: '200000000000000000000', + markets: [[Object], [Object], [Object], [Object], [Object], [Object], [Object]], __typename: 'Pool', }, { - id: '0x1f10f3ba7acb61b2f50b9d6ddcf91a6f787c0e82', - name: 'Pool 2', + id: '0x525c7063e7c20997baae9bda922159152d0e8417', + name: 'Pool 1', creator: '0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266', - blockPosted: '240', - timestampPosted: '1694787802', + blockPosted: '253', + timestampPosted: '1706291640', category: '', logoUrl: '', description: '', priceOracleAddress: '0x322813fd9a801c5507c9de605d63cea4f2ce6c44', - closeFactorMantissa: '600000000000000000', - liquidationIncentiveMantissa: '3000000000000000000', - minLiquidatableCollateralMantissa: '200000000000000000000', - markets: [Array], + closeFactorMantissa: '50000000000000000', + liquidationIncentiveMantissa: '1000000000000000000', + minLiquidatableCollateralMantissa: '100000000000000000000', + markets: [[Object], [Object]], __typename: 'Pool', }, ];