Commit d5226e85 authored by Annie Ke's avatar Annie Ke Committed by Mark Tyneway

wip: surgery predeploy tests

parent 3a87ac26
......@@ -39,13 +39,14 @@
"eslint-plugin-prettier": "^3.4.0",
"eslint-plugin-react": "^7.24.0",
"eslint-plugin-unicorn": "^32.0.1",
"ethereum-waffle": "^3.4.0",
"ethereumjs-util": "^7.1.3",
"ethers": "^5.4.5",
"lint-staged": "11.0.0",
"mocha": "^9.1.2",
"node-fetch": "2.6.5",
"solc": "0.8.7-fixed",
"ts-node": "^10.0.0",
"ts-mocha": "^8.0.0"
"ts-mocha": "^8.0.0",
"ts-node": "^10.0.0"
}
}
......@@ -5,6 +5,7 @@ import chaiAsPromised from 'chai-as-promised'
import * as dotenv from 'dotenv'
import { getenv, remove0x } from '@eth-optimism/core-utils'
import { providers, BigNumber } from 'ethers'
import { solidity } from 'ethereum-waffle'
import { SurgeryDataSources, Account, AccountType } from '../scripts/types'
import { loadSurgeryData } from '../scripts/data'
import { classify } from '../scripts/classifiers'
......@@ -12,6 +13,7 @@ import { GenesisJsonProvider } from './provider'
// Chai plugins go here.
chai.use(chaiAsPromised)
chai.use(solidity)
const should = chai.should()
const expect = chai.expect
......@@ -19,6 +21,9 @@ const expect = chai.expect
dotenv.config()
export const NUM_ACCOUNTS_DIVISOR = 4096
export const ERC20_ABI = [
'function balanceOf(address owner) view returns (uint256)',
]
interface TestEnvConfig {
preL2ProviderUrl: string | null
......
......@@ -2,11 +2,9 @@ import { ethers } from 'ethers'
import { abi as UNISWAP_POOL_ABI } from '@uniswap/v3-core/artifacts/contracts/UniswapV3Pool.sol/UniswapV3Pool.json'
import { UNISWAP_V3_NFPM_ADDRESS } from '../scripts/constants'
import { getUniswapV3Factory, replaceWETH } from '../scripts/utils'
import { expect, env } from './setup'
import { expect, env, ERC20_ABI } from './setup'
import { AccountType } from '../scripts/types'
const ERC20_ABI = ['function balanceOf(address owner) view returns (uint256)']
describe('uniswap contracts', () => {
before(async () => {
await env.init()
......
......@@ -6861,7 +6861,7 @@ ethereum-cryptography@^0.1.2, ethereum-cryptography@^0.1.3:
secp256k1 "^4.0.1"
setimmediate "^1.0.5"
ethereum-waffle@^3.3.0:
ethereum-waffle@^3.3.0, ethereum-waffle@^3.4.0:
version "3.4.0"
resolved "https://registry.yarnpkg.com/ethereum-waffle/-/ethereum-waffle-3.4.0.tgz#990b3c6c26db9c2dd943bf26750a496f60c04720"
integrity sha512-ADBqZCkoSA5Isk486ntKJVjFEawIiC+3HxNqpJqONvh3YXBTNiRfXvJtGuAFLXPG91QaqkGqILEHANAo7j/olQ==
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment