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

feat: add btt tests for BCoWPool commit #162

Merged
merged 4 commits into from
Jul 22, 2024
Merged

feat: add btt tests for BCoWPool commit #162

merged 4 commits into from
Jul 22, 2024

Conversation

0xteddybear
Copy link

No description provided.

├── when sender is not solution settler
│ └──it should revert
└── when sender is solution settler
├── when reentrancy lock is set
Copy link
Member

Choose a reason for hiding this comment

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

other way around? 1st reentrancy is checked, then the sender

Copy link
Member

Choose a reason for hiding this comment

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

i'd go for:

when reentrancy lock is set -> should revert
when sender is not solution settler -> should revert
when called (or preconditions are met) -> should set the reentrancy lock

Comment on lines 26 to 30
function test_WhenPreconditionsAreMet() external whenPreconditionsAreMet {
function test_FinalizeWhenPreconditionsAreMet() external whenPreconditionsAreMet {
Copy link
Member

@wei3erHase wei3erHase Jul 17, 2024

Choose a reason for hiding this comment

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

why are we changing this line? is it that single tree bulloak skips the method?

@0xteddybear 0xteddybear requested a review from wei3erHase July 17, 2024 22:53
wei3erHase
wei3erHase previously approved these changes Jul 18, 2024
Copy link
Member

@wei3erHase wei3erHase left a comment

Choose a reason for hiding this comment

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

👍

Base automatically changed from test/btt-finalize to dev July 22, 2024 17:00
@wei3erHase wei3erHase dismissed their stale review July 22, 2024 17:00

The base branch was changed.

@0xteddybear 0xteddybear requested a review from wei3erHase July 22, 2024 17:56
@@ -6,3 +6,11 @@ BCoWPool::_afterFinalize
│ └── it returns
└── when factorys logBCoWPool reverts
└── it emits a COWAMMPoolCreated event

BCoWPool::Commit
Copy link
Member

Choose a reason for hiding this comment

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

i don't get why we need to capitalize, it's not on BPool.tree

Copy link
Member

@wei3erHase wei3erHase left a comment

Choose a reason for hiding this comment

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

👍

@wei3erHase wei3erHase changed the title Test/btt commit feat: add btt tests for BCoWPool commit Jul 22, 2024
@0xteddybear 0xteddybear merged commit 76ea1ef into dev Jul 22, 2024
4 checks passed
@0xteddybear 0xteddybear deleted the test/btt-commit branch July 22, 2024 19:14
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.

2 participants