Skip to content

jamesbachini/Uniswap-v4-Tests

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Uniswap v4 Tests

A Uniswap v4 hook which creates an afterSwap hook to check if price is above or below 1:1 for a stable pair. After a swap takes place if price is below 1:1 it will rebalance the pool either by adding liquidity or making a swap.

Test in foundry (recommend using WSL or a unix based OS)

curl -L https://foundry.paradigm.xyz | bash
source /home/james/.bashrc
foundryup
forge install https://github.com/Uniswap/v4-core --no-commit
forge install openzeppelin/openzeppelin-contracts --no-commit
forge install marktoda/forge-gas-snapshot --no-commit
forge test

More info on Uniswap v4 hooks at https://jamesbachini.com/uniswap-v4-hooks/

About

A test suite for working with Uniswap v4 Hooks

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published