hifi
hifi copied to clipboard
Monorepo implementing the Hifi fixed-rate, fixed-term lending protocol
Unfortunately, the script I wrote last month is still failing in [certain](https://github.com/hifi-finance/hifi/issues/22#issuecomment-920760316) circumstances. I will switch back to running integration on all packages, regardless of what has been modified. I...
These functions are tested as part of the integration tests for the trade functions, but we should go the extra mile and write unit tests for them.
The `@actions/setup-node@v2` action is used in four jobs in the CI workflow, which causes the following error: > Unable to reserve cache with key node-cache-Linux-yarn-ed73988f6a7bd1a0270433a2d2ff89c15016643cf8f05a2fb87a270786528399, another job may be creating...
We can do this once Waffle adds support for checking against a subset of args emitted in events.
That is, on [line 254](https://github.com/hifi-finance/hifi-amm/blob/2f53c72fbd4feed1ddcce0d6d40d6f6a9d1c0968/contracts/HifiPool.sol#L254) in `HifiPool`. This is not a priority because there isn't enough DAI or USDC in existence for a phantom overflow to be possible.
There are many number constants duplicated across the `YieldSpace` tests. We should use one of the following tools to enable shared snapshots in a declarative way: + [mocha-chai-jest-snapshot](https://github.com/mochiya98/mocha-chai-jest-snapshot) + [snap-shot-it](https://github.com/bahmutov/snap-shot-it)
See the [documentation](https://ethereum-waffle.readthedocs.io/en/latest/matchers.html#change-token-balance).
Consider implementing a library for the `normalize` and the `denormalize` functions. See how I implemented them in the [amm](https://github.com/hifi-finance/hifi-amm/blob/c71807ab9f13ad8cce7536a0552a428f1255de03/contracts/HifiPool.sol#L310-L328).
See the [Hardhat guide](https://hardhat.org/guides/mainnet-forking.html).