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

update amplitude runtime to support XCM reserve transfer for USDT #290

Merged

Conversation

b-yap
Copy link
Contributor

@b-yap b-yap commented Aug 2, 2023

Closes task #83

General overview of the changes:

Aside from the tasks mentioned in the ticket, this PR also includes:

  • adding Statemine and its USDT in the xcm configuration of Amplitude.
  • updating the test cases that will cater to both the pendulum and amplitude.
    • moving up the project from runtime/integration-tests/pendulum to runtime/integration-tests
    • moved ALL dependencies under [dev-dependencies] (see the updated Cargo.toml)
    • combined setup.rs and polkadot_test_net.rs into mock.rs
    • created a macro for the test cases: test_macros.rs
    • broke down tests.rs to 2: pendulum_tests.rs and amplitude_tests.rs

note: Statemint and Statemine have different issued balances, after performing XTokens::transfer() in Pendulum and Amplitude. See line 454 to 456 in test_macros.rs.

@b-yap b-yap marked this pull request as ready for review August 4, 2023 12:37
@b-yap b-yap requested a review from a team August 4, 2023 12:38
runtime/common/src/lib.rs Outdated Show resolved Hide resolved
runtime/integration-tests/src/mock.rs Outdated Show resolved Hide resolved
Copy link
Member

@ebma ebma left a comment

Choose a reason for hiding this comment

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

Thanks for adding my requested changes @b-yap.

While at first, it might seem like there is still some code that can be deduplicated, I think it's good the way it is right now. For example, some parameters like the IDs are shared between the Polkadot and Kusama asset hub, but still have separate definitions in runtime/common/src/lib.rs but I think it's better this way because we can't necessarily always assume that this is the case. There could have been differences since the Polkadot and Kusama AssetHub are different parachains after all.

LGTM

@b-yap b-yap force-pushed the 83-update-amplitude-runtime-to-support-xcm-reserve-transfer-for-usdt branch from 83c56da to ad1ad33 Compare August 7, 2023 11:07
@ebma ebma self-requested a review August 7, 2023 12:36
@ebma
Copy link
Member

ebma commented Aug 7, 2023

The previous CI already passed and we only added comments so I will merge it without waiting.

@ebma ebma merged commit 6f92a8d into main Aug 7, 2023
2 checks passed
@ebma ebma deleted the 83-update-amplitude-runtime-to-support-xcm-reserve-transfer-for-usdt branch August 7, 2023 12:37
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