Skip to content

Commit

Permalink
fix: fix matchstick tests
Browse files Browse the repository at this point in the history
  • Loading branch information
coreyar committed Dec 5, 2024
1 parent 1368ea4 commit ff1de9a
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 26 deletions.
38 changes: 28 additions & 10 deletions subgraphs/isolated-pools/src/constants/addresses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,34 @@ import {
} from './config';

export const poolRegistryAddress = Address.fromString(poolRegistryAddressString);
const nullAddressString = '0x0000000000000000000000000000000000000000';
export const nullAddress = Address.fromString(nullAddressString);

export const nullAddress = Address.fromString('0x0000000000000000000000000000000000000000');

export const vBifiAddress = Address.fromString(vBifiAddressString);
export const vLisUsdAddress = Address.fromString(vLisUsdAddressString);
export const vagEURAddress = Address.fromString(vagEURAddressString);
export const vBifiAddress = Address.fromString(
vBifiAddressString.length > 0 ? vBifiAddressString : nullAddressString,
);
export const vLisUsdAddress = Address.fromString(
vLisUsdAddressString.length > 0 ? vLisUsdAddressString : nullAddressString,
);
export const vagEURAddress = Address.fromString(
vagEURAddressString.length > 0 ? vagEURAddressString : nullAddressString,
);
export const vankrBNBLiquidStakedBNBAddress = Address.fromString(
vankrBNBLiquidStakedBNBAddressString,
vankrBNBLiquidStakedBNBAddressString.length > 0
? vankrBNBLiquidStakedBNBAddressString
: nullAddressString,
);
export const vankrBNBDeFiAddress = Address.fromString(
vankrBNBDeFiAddressString.length > 0 ? vankrBNBDeFiAddressString : nullAddressString,
);
export const vSnBNBAddress = Address.fromString(
vSnBNBAddressString.length > 0 ? vSnBNBAddressString : nullAddressString,
);
export const vWETHLiquidStakedETHAddress = Address.fromString(
vWETHLiquidStakedETHAddressString.length > 0
? vWETHLiquidStakedETHAddressString
: nullAddressString,
);
export const vWETHCoreAddress = Address.fromString(
vWETHCoreAddressString.length > 0 ? vWETHCoreAddressString : nullAddressString,
);
export const vankrBNBDeFiAddress = Address.fromString(vankrBNBDeFiAddressString);
export const vSnBNBAddress = Address.fromString(vSnBNBAddressString);
export const vWETHLiquidStakedETHAddress = Address.fromString(vWETHLiquidStakedETHAddressString);
export const vWETHCoreAddress = Address.fromString(vWETHCoreAddressString);
30 changes: 14 additions & 16 deletions subgraphs/isolated-pools/src/constants/config-template
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
// Use yarn prepare commands to generate config typescript file per env

export const poolRegistryAddress = '{{ poolRegistryAddress }}';
// @ts-ignore When the template is created this will fallback to a null string
export const vBifiAddress = '{{ vBifiAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vLisUsdAddress = '{{ vLisUsdAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vagEURAddress = '{{ vagEURAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vankrBNBLiquidStakedBNBAddress = '{{ vankrBNBLiquidStakedBNBAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vankrBNBDeFiAddress = '{{ vankrBNBDeFiAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vSnBNBAddress = '{{ vSnBNBAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vWETHLiquidStakedETHAddress = '{{ vWETHLiquidStakedETHAddress }}' || '0x0000000000000000000000000000000000000000'
// @ts-ignore When the template is created this will fallback to a null string
export const vWETHCoreAddress = '{{ vWETHCoreAddress }}' || '0x0000000000000000000000000000000000000000'

export const vBifiAddress = '{{ vBifiAddress }}'

export const vLisUsdAddress = '{{ vLisUsdAddress }}'

export const vagEURAddress = '{{ vagEURAddress }}'

export const vankrBNBLiquidStakedBNBAddress = '{{ vankrBNBLiquidStakedBNBAddress }}'

export const vankrBNBDeFiAddress = '{{ vankrBNBDeFiAddress }}'

export const vSnBNBAddress = '{{ vSnBNBAddress }}'

export const vWETHLiquidStakedETHAddress = '{{ vWETHLiquidStakedETHAddress }}'

export const vWETHCoreAddress = '{{ vWETHCoreAddress }}'

0 comments on commit ff1de9a

Please sign in to comment.