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

Twap: Integrate and Add migration tests #2429

Merged
merged 5 commits into from
Aug 22, 2022
Merged

Conversation

mattverse
Copy link
Member

Closes: #2198

What is the purpose of the change

Integrates and adds migration test. The migration logic is implemented using the last pool id, not by creating a method that iterates through all pools and gets all pool IDs.

This PR also introduces test cases for the upgrade itself, and the migration method.

Brief Changelog

Add migration test for existing pools on the twap module.

Documentation and Release Note

  • Does this pull request introduce a new feature or user-facing behavior changes? no
  • Is a relevant changelog entry added to the Unreleased section in CHANGELOG.md? no
  • How is the feature or change documented? not documented

@mattverse mattverse requested a review from a team August 17, 2022 11:24
@github-actions github-actions bot added the C:app-wiring Changes to the app folder label Aug 17, 2022
app/upgrades/v12/upgrade_test.go Outdated Show resolved Hide resolved
app/upgrades/v12/upgrade_test.go Show resolved Hide resolved
x/twap/migrate_test.go Outdated Show resolved Hide resolved
app/upgrades/v12/upgrade_test.go Show resolved Hide resolved
x/twap/migrate_test.go Outdated Show resolved Hide resolved
x/twap/migrate_test.go Show resolved Hide resolved
@mattverse mattverse mentioned this pull request Aug 18, 2022
7 tasks
Copy link
Member

@p0mvn p0mvn left a comment

Choose a reason for hiding this comment

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

Great work @mattverse

I skimmed the original issue and I think there might be one point that needs to be addressed:

add an upgrade test for v11, that ensures were still producing blocks with swaps post-upgrade.

I think that implies adding an e2e test. We currently don't have any doins swaps, only creating pools.

Can we either add it here or create an issue, attaching it to the v12 milestone blocker, please?

I'm also happy to help with adding this check to e2e

x/twap/migrate_test.go Show resolved Hide resolved
x/twap/migrate_test.go Show resolved Hide resolved
Copy link
Contributor

@alexanderbez alexanderbez left a comment

Choose a reason for hiding this comment

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

ACK (pending review comments being addressed 👍 )

app/upgrades/v12/upgrade_test.go Show resolved Hide resolved
@czarcas7ic czarcas7ic added this to the V12 Blockers milestone Aug 18, 2022
@github-actions github-actions bot added the C:x/twap Changes to the twap module label Aug 19, 2022
@ValarDragon
Copy link
Member

I think we should merge this after @p0mvn 's comment for transient store being tested is addressed

@mattverse
Copy link
Member Author

Addressed! Merging :)

@mattverse mattverse merged commit 6ba11f1 into main Aug 22, 2022
@mattverse mattverse deleted the mattverse/twap-migration-test branch August 22, 2022 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C:app-wiring Changes to the app folder C:x/twap Changes to the twap module
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

TWAP: Integrate & test migration logic
5 participants