Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wip: LUSD Chicken Bonds Implementation #21

Merged
merged 39 commits into from
Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from 37 commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
fd77add
chore: forge init
RickGriff Feb 11, 2022
fa8cc84
forge install: ds-test
RickGriff Feb 17, 2022
96c3047
forge install: openzeppelin-contracts
RickGriff Feb 17, 2022
c663c1f
Implement createBond functionality
RickGriff Feb 17, 2022
542da78
Implement chickenOut functionality
RickGriff Feb 17, 2022
307f4dd
Implement chickenIn functionality
RickGriff Feb 18, 2022
6e5b2f6
Fix bond cap function
RickGriff Feb 19, 2022
8b94790
Add redemption functionality
RickGriff Feb 19, 2022
f51be4c
Move LUSDChickenBonds files into folder
RickGriff Feb 19, 2022
77ebad6
Merge branch 'main' of https://github.com/liquity/ChickenBond
RickGriff Feb 19, 2022
befa155
Remove duplicate files
RickGriff Feb 19, 2022
739668b
Add tests for redeem
RickGriff Feb 20, 2022
8116b19
Re-order chickenOut state updates
RickGriff Feb 21, 2022
f6b962e
chore: convert ds-test and openzeppelin-contracts to submodules
danielattilasimon Feb 22, 2022
40087c9
Implement shiftLUSDFromSPToCurve, make redemption impact only acquire…
RickGriff Feb 23, 2022
68ac2aa
Implement shiftLUSDFromCurveToSP functionality
RickGriff Feb 24, 2022
dc07f81
Make sLUSD Accrual non-linear and implement chickenIn LUSD refund
RickGriff Mar 2, 2022
fafa031
Replace 'uint' with 'uint256'
RickGriff Mar 2, 2022
8243b9d
Add non-zero require to functions and add extra tests
RickGriff Mar 3, 2022
673670e
forge install: forge-std
RickGriff Mar 11, 2022
e17eb53
Split test setup into mainnet and dev components
RickGriff Mar 14, 2022
94dd839
Integrate Yearn Registry and add share value calc
RickGriff Mar 21, 2022
1e13d5f
Fix NFT minting bug - add totalMinted counter
RickGriff Mar 21, 2022
dfd7adc
Fix chickenIn Yearn withdrawal arithmetic
RickGriff Mar 23, 2022
894745e
Fix chickenOut withdrawal arithmetic & add totalMinted tests
RickGriff Mar 23, 2022
cee7b9e
Replace shareValue calc with pricePerShare, and fix rounding error bug
RickGriff Mar 25, 2022
4bc5784
Remove redundant test code
RickGriff Mar 25, 2022
1584fc3
Integrate mainnet Curve pool and Yearn Curve vault
RickGriff Apr 1, 2022
742767f
Tweak tests
RickGriff Apr 7, 2022
7377bcc
Extract bond creation test helper
RickGriff Apr 7, 2022
d93780b
Fix mock pricePerShare for development tests
RickGriff Apr 7, 2022
6164432
Add missing prank endings in tests
RickGriff Apr 8, 2022
72328c4
Add artificial totalSupply to mock Curve pool
RickGriff Apr 8, 2022
82ea99a
Remove warnings
bingen Apr 11, 2022
2b6ec75
Remove SafeMath from mock contract
bingen Apr 12, 2022
71d5bf0
Make shifting functions revert when crossing the Curve 1.0 price boun…
RickGriff Apr 12, 2022
bfca2e3
Merge branch 'lusd_chicken_bonds' of https://github.com/liquity/Chick…
RickGriff Apr 12, 2022
0a2dd22
Remove DS_Store
RickGriff Apr 13, 2022
80ade5d
--no-edit
RickGriff Apr 13, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
.idea
cache/
out/
.idea
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess we can .gitignore .DS_Store too.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And solc binary too.

9 changes: 9 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[submodule "LUSDChickenBonds/lib/ds-test"]
path = LUSDChickenBonds/lib/ds-test
url = https://github.com/dapphub/ds-test
[submodule "LUSDChickenBonds/lib/openzeppelin-contracts"]
path = LUSDChickenBonds/lib/openzeppelin-contracts
url = https://github.com/openzeppelin/openzeppelin-contracts
[submodule "LUSDChickenBonds/lib/forge-std"]
path = LUSDChickenBonds/lib/forge-std
url = https://github.com/brockelmore/forge-std
Binary file added LUSDChickenBonds/.DS_Store
Binary file not shown.
Loading