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

Fix CI + one integration test for bridge-hub-kusama #397

Merged
merged 9 commits into from
Jul 24, 2024

Conversation

bkontur
Copy link
Contributor

@bkontur bkontur commented Jul 23, 2024

Closes: #396

This PR:

  • fixes CI test pipelines to block PRs when tests fail. See more details here.
  • Fixes an integration test for bridge-hub-kusama-integration-tests that was not caught due to a previous CI bug.
  • Includes some minor cleanup, changing Versioned*::V4 to Versioned*::from to use the latest version (for easier migration to xcm:v5).

TODO

  • fix the integration tests
  • Does not require a CHANGELOG entry

.github/workflows/changelog.yml Outdated Show resolved Hide resolved
.github/workflows/changelog.yml Outdated Show resolved Hide resolved
bkontur and others added 2 commits July 23, 2024 16:17
@bkontur bkontur changed the title Fix inegration tests for bridge-hub-kusama Fix integration tests for bridge-hub-kusama Jul 24, 2024
@bkontur bkontur changed the title Fix integration tests for bridge-hub-kusama Fix integration test for bridge-hub-kusama Jul 24, 2024
@bkontur bkontur changed the title Fix integration test for bridge-hub-kusama Fix CI + one integration test for bridge-hub-kusama Jul 24, 2024
@bkontur bkontur mentioned this pull request Jul 24, 2024
1 task
@bkontur bkontur marked this pull request as ready for review July 24, 2024 09:34
// Sender's balance is reduced
assert_eq!(sender_ksms_after, sender_ksms_before - amount - delivery_fees);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this no longer the case or are you just making the test less brittle?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was not correct, at least, it missed the subtraction of execution_fees. I tried to add them as well, but let result = Runtime::dry_run_call(origin, call).unwrap(); did not return actual_weight, so it is not possible to calculate WeightToFee. Additionally, there was some calculation of intermediate_delivery_fees_amount from BHK to BHP, which is not relevant. So yes, keep it simple. At least I added asserts to check that the dry-run succeeded and the message is ready to be relayed over bridge to the BHP.

Copy link
Contributor

Choose a reason for hiding this comment

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

This was added by @franciscoaguirre, fee estimation doesn't yet work with BridgeHub exporters: #380 (comment)

The check will be added back when that is fixed as well.

@bkchr
Copy link
Contributor

bkchr commented Jul 24, 2024

/merge

@fellowship-merge-bot fellowship-merge-bot bot enabled auto-merge (squash) July 24, 2024 10:43
@fellowship-merge-bot
Copy link
Contributor

Enabled auto-merge in Pull Request

Available commands
  • /merge: Enables auto-merge for Pull Request
  • /merge cancel: Cancels auto-merge for Pull Request
  • /merge help: Shows this menu

For more information see the documentation

@fellowship-merge-bot
Copy link
Contributor

Failed to update PR ❌

There was an error while trying to keep this PR up-to-date

You may have conflicts ‼️ or may have to manually sync it with the target branch 👉❇️

More info in the logs 📋

@fellowship-merge-bot fellowship-merge-bot bot merged commit c61e836 into polkadot-fellows:main Jul 24, 2024
44 checks passed
@bkontur bkontur deleted the bko-fix-tests branch July 24, 2024 12:49
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.

Check merge bot and required pipelines
7 participants