A smart contract application for implementing upgradeable smart contract via UUPS. Users should be able to use implementation of BoxV1. When Users want to upgrade the implementation contract (that is BoxV2), it will be running clearly.
- git
- You'll know you did it right if you can run
git --version
and you see a response likegit version x.x.x
- You'll know you did it right if you can run
- foundry
- You'll know you did it right if you can run
forge --version
and you see a response likeforge 0.2.0 (816e00b 2023-03-16T00:05:26.396218Z)
- You'll know you did it right if you can run
git clone https://github.com/hrmneffdii/foundry-upgradeable-contract
cd foundry-upgradeable-contract
forge build
- Start a local node
make anvil
- Deploy
This will default to your local node. You need to have it running in another terminal in order for it to deploy.
make deploy
make test
make coverage
and for coverage based testing:
make coverage-debug
- In Scope:
./src/
|── BoxV1.sol
└── BoxV2.sol
- Solc Version: 0.8.19
- Chain(s) to deploy contract to: Ethereum