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

Migration contracts & migration tests #153

Open
wants to merge 63 commits into
base: main
Choose a base branch
from
Open

Conversation

AStox
Copy link
Contributor

@AStox AStox commented Sep 21, 2023

No description provided.

@AStox AStox marked this pull request as ready for review September 29, 2023 18:49
src/PoolManager.sol Outdated Show resolved Hide resolved
ilinzweilin and others added 20 commits October 17, 2023 07:56
* Explore new approval flow

* Fix permit logic

* Allowance checks

* Remove fee-on-transfer support

* Fix revert message

* Fix tests

* Remove unused function from interface

* Fix comment

* Naming

* Remove console

* Remove duplicate transfer from function

* Fix balance check

* Add operator param

* Align naming of view functions

* Address pr comments
* fix frontrunning with smaller asset amounts with permits

* add test condition

Signed-off-by: ilin <[email protected]>

---------

Signed-off-by: ilin <[email protected]>
* Make restrictionManagerFactory mutable on PoolManager

* group RestrictionManagerFactory with other public vars
* Remove preview methods from investment mgr

* Add comment

* Format

* Update src/InvestmentManager.sol

Co-authored-by: Adam Stox <[email protected]>

* Update src/InvestmentManager.sol

Co-authored-by: Adam Stox <[email protected]>

* Update src/InvestmentManager.sol

Co-authored-by: Adam Stox <[email protected]>

* Update src/InvestmentManager.sol

Co-authored-by: Adam Stox <[email protected]>

* Update src/InvestmentManager.sol

Co-authored-by: Adam Stox <[email protected]>

---------

Co-authored-by: Adam Stox <[email protected]>
* Add IERC7540

* Update interface

* Update ERC-20 interfaces

* Fix comment

* Skip slither step
* Add test for failing price conversion on decrease

* Attempt to fix conversions
* Automatically claim deposits on trigger request redeem

* trigger redemptions when user still has tokens in escrow (#189)

* trigger redemptions when user still has tokens in escrow

Signed-off-by: ilin <[email protected]>

* fix comments

Signed-off-by: ilin <[email protected]>

* add fixes from review

* add fixes from review

* add fixes from review

---------

Signed-off-by: ilin <[email protected]>

---------

Signed-off-by: ilin <[email protected]>
Co-authored-by: Alina Sinelnikova <[email protected]>
@hieronx hieronx changed the base branch from tests to main October 26, 2023 12:36
Copy link

Coverage after merging migration-contracts into main will be

82.10%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   Escrow.sol100%100%100%100%
   InvestmentManager.sol91.44%70.97%97.22%98.11%145, 149, 154, 185, 189, 194, 234, 260, 310, 341, 417, 423–424, 454, 490–491, 534, 536, 580, 639–640
   LiquidityPool.sol95.24%80%97.44%98.51%101, 112, 128–129, 164
   PoolManager.sol96.25%88.46%100%100%182, 198, 224, 235, 316, 324, 336, 341, 367
   Root.sol100%100%100%100%
   UserEscrow.sol100%100%100%100%
src/admins
   DelayedAdmin.sol100%100%100%100%
   PauseAdmin.sol100%100%100%100%
src/gateway
   Gateway.sol94.59%83.33%100%98.88%336, 348, 360, 373, 386, 389, 405, 412
   Messages.sol63.44%37.50%60.47%65.95%1000, 1000, 1000–1001, 1005, 105, 124, 155, 208, 216, 251, 296–299, 395, 403–407, 431, 439, 463, 471, 495, 503, 523, 531–534, 554, 562–565, 576, 619, 663, 710, 749, 761, 787, 824–827, 843–846, 857, 86, 883, 906, 936, 967–968, 970–971, 971, 971–972, 974, 978, 982, 999
src/gateway/routers/axelar
   Router.sol100%100%100%100%
src/gateway/routers/xcm
   Router.sol0%0%0%0%103, 103, 103–104, 106, 109, 114, 119, 121, 123, 142, 157, 157, 157–159, 159, 159, 161–162, 162, 162–164, 164, 164–166, 166, 166–168, 168, 168–170, 170, 170–172, 172, 172–173, 175, 182–183, 185, 189–191, 193, 197, 90, 90, 90–91, 93, 96
src/token
   ERC20.sol95.42%92.86%92.86%97.33%199, 228, 67, 85–86
   RestrictionManager.sol93.62%87.50%100%95.65%71–72, 96
   Tranche.sol92.68%100%75%100%
src/util
   Auth.sol100%100%100%100%
   BytesLib.sol0%0%0%0%10, 10, 10, 102, 102, 102–103, 106, 109, 11, 11, 11, 113, 113, 113–114, 117, 120, 124, 124, 124–125, 128, 13, 131, 65, 69, 69, 69–70, 73, 76, 80, 80, 80–81, 84, 87, 91, 91, 91–92, 95, 98
   Factory.sol100%100%100%100%
   MathLib.sol0%0%0%0%105–106, 106, 106–107, 109, 114, 114, 114–115, 117, 24–25, 28–29, 33, 33, 33, 37, 41, 41, 41, 48, 51, 54–55, 63, 66, 69, 72, 76, 81, 86–91, 97–98
   SafeTransferLib.sol87.50%66.67%100%100%28, 38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants