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: support new substrate-contracts-node structure and stabilize integration tests #360

Merged
merged 8 commits into from
Dec 3, 2024

Conversation

AlexD10S
Copy link
Collaborator

@AlexD10S AlexD10S commented Dec 1, 2024

This PR introduces various fixes:

1- The latest release of substrate-contracts-node https://github.com/paritytech/substrate-contracts-node/releases/tag/v0.42.0 introduced a new directory structure for binary extraction. This change caused pop-cli to fail when attempting to use the latest version. The logic has been updated to support both the old structure and the new structure.

2- The CI has been failing in the integration test launch_paseo_and_system_parachain due to issues with version compatibility. The test now explicitly sets the version of Paseo to v1.3.3 where coretime-paseo-local was introduced.

3- Updated CI to trigger on events like opened, synchronize, reopened, and ready_for_review, instead of only for PRs targeting main.

4- The function run_contracts_node has been updated to allow specifying the port for running the substrate-contracts-node. This improvement facilitates running unit tests in parallel without port conflicts

Copy link

codecov bot commented Dec 2, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 27 lines in your changes missing coverage. Please review.

Project coverage is 72.59%. Comparing base (258a4b2) to head (0f1605e).
Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
crates/pop-contracts/src/node/mod.rs 50.00% 7 Missing and 2 partials ⚠️
crates/pop-contracts/src/call.rs 40.00% 0 Missing and 6 partials ⚠️
crates/pop-contracts/src/up.rs 50.00% 0 Missing and 4 partials ⚠️
crates/pop-common/src/sourcing/mod.rs 50.00% 0 Missing and 3 partials ⚠️
crates/pop-cli/src/commands/up/contract.rs 0.00% 2 Missing ⚠️
crates/pop-cli/src/common/contracts.rs 0.00% 2 Missing ⚠️
crates/pop-parachains/src/build.rs 0.00% 0 Missing and 1 partial ⚠️
@@            Coverage Diff             @@
##             main     #360      +/-   ##
==========================================
+ Coverage   70.47%   72.59%   +2.12%     
==========================================
  Files          54       56       +2     
  Lines        9250    10700    +1450     
  Branches     9250    10700    +1450     
==========================================
+ Hits         6519     7768    +1249     
- Misses       1737     1844     +107     
- Partials      994     1088      +94     
Files with missing lines Coverage Δ
crates/pop-common/src/lib.rs 61.29% <ø> (ø)
crates/pop-contracts/src/testing.rs 76.92% <100.00%> (ø)
crates/pop-parachains/src/build.rs 88.88% <0.00%> (+0.11%) ⬆️
crates/pop-cli/src/commands/up/contract.rs 18.38% <0.00%> (-5.51%) ⬇️
crates/pop-cli/src/common/contracts.rs 24.00% <0.00%> (+24.00%) ⬆️
crates/pop-common/src/sourcing/mod.rs 85.85% <50.00%> (+0.09%) ⬆️
crates/pop-contracts/src/up.rs 80.20% <50.00%> (+2.30%) ⬆️
crates/pop-contracts/src/call.rs 81.14% <40.00%> (+2.51%) ⬆️
crates/pop-contracts/src/node/mod.rs 64.62% <50.00%> (-0.09%) ⬇️

... and 9 files with indirect coverage changes

Copy link
Contributor

@al3mart al3mart left a comment

Choose a reason for hiding this comment

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

Looks good. Thanks for addressing this!

@AlexD10S AlexD10S merged commit d1cf48d into main Dec 3, 2024
19 of 20 checks passed
@AlexD10S AlexD10S deleted the alex/fix-ci branch December 3, 2024 11:35
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