Skip to content

Commit

Permalink
enable jest
Browse files Browse the repository at this point in the history
  • Loading branch information
galekseev committed Oct 23, 2023
1 parent a0202c6 commit b6aa71e
Show file tree
Hide file tree
Showing 4 changed files with 880 additions and 18 deletions.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@
"@uniswap/permit2-sdk": "1.2.0",
"ethereumjs-util": "7.1.5",
"ethers": "6.6.3",
"hardhat-deploy": "0.11.34"
"hardhat-deploy": "0.11.34",
"mocha-chai-jest-snapshot": "1.1.4"
},
"devDependencies": {
"@nomicfoundation/hardhat-chai-matchers": "2.0.1",
Expand Down
5 changes: 5 additions & 0 deletions src/prelude.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ import { Assertion, AssertionError, assert, expect, config, should } from 'chai'
import { parseUnits } from 'ethers';
import { time } from '@nomicfoundation/hardhat-network-helpers';

import { use } from 'chai';
import { jestSnapshotPlugin } from 'mocha-chai-jest-snapshot';
use(jestSnapshotPlugin());


export const constants = {
ZERO_ADDRESS: '0x0000000000000000000000000000000000000000',
EEE_ADDRESS: '0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE',
Expand Down
3 changes: 2 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"resolveJsonModule": true,
"strictNullChecks": true,
"typeRoots": ["node_modules/@types"],
"lib": ["es2020", "dom", "esnext"]
"lib": ["es2020", "dom", "esnext"],
"skipLibCheck": true,
}
}
Loading

0 comments on commit b6aa71e

Please sign in to comment.