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

test: integration tests, doc tests and improve coverage #242

Merged
merged 13 commits into from
Jul 11, 2024

Conversation

AlexD10S
Copy link
Collaborator

@AlexD10S AlexD10S commented Jul 5, 2024

PR focused on improving the testing:

  • Integration test to cover the entire parachain lifecycle: new (all the supported templates), build, up
  • Integration test to cover the entire contract lifecycle: new (all the supported templates), build, up, call
    This 2 tasks closes test: integration test for complete contract process #218
  • Flag skip_confirm to skip user confirmation in pop up parachain. Needed for integration tests, and closes Flag to skip user confirmation #208
  • In CI, run integration tests for ubuntu and macOS.
  • Fix crate documentation and ensure the tests pass:
    - To try in crates/pop_contracts run cargo test --doc
    - To try in crates/pop_parachains run cargo test --doc
  • Add the check cargo test --doc in CI to ensure documentation is updated with code changes.
  • Add some missing unit tests in the pop_contracts crate.
  • Ensure the contracts node process is killed after the tests, solving an issue encountered when running the tests locally.

@r0gue-io r0gue-io deleted a comment from codecov bot Jul 5, 2024
Copy link

codecov bot commented Jul 5, 2024

Codecov Report

Attention: Patch coverage is 61.33333% with 58 lines in your changes missing coverage. Please review.

Project coverage is 70.81%. Comparing base (70d3869) to head (b9e8d77).

@@            Coverage Diff             @@
##             main     #242      +/-   ##
==========================================
+ Coverage   70.46%   70.81%   +0.34%     
==========================================
  Files          47       47              
  Lines        7536     7664     +128     
  Branches     7536     7664     +128     
==========================================
+ Hits         5310     5427     +117     
+ Misses       1333     1315      -18     
- Partials      893      922      +29     
Files Coverage Δ
crates/pop-contracts/src/errors.rs 0.00% <ø> (ø)
crates/pop-contracts/src/up.rs 77.65% <50.00%> (-0.05%) ⬇️
crates/pop-contracts/src/utils/contracts_node.rs 63.71% <42.85%> (+0.98%) ⬆️
crates/pop-contracts/src/utils/helpers.rs 81.81% <78.94%> (+3.09%) ⬆️
crates/pop-contracts/src/utils/signer.rs 84.37% <81.81%> (+44.37%) ⬆️
crates/pop-cli/src/commands/up/contract.rs 26.22% <0.00%> (-0.36%) ⬇️
crates/pop-contracts/src/call.rs 79.06% <74.64%> (+9.22%) ⬆️
crates/pop-cli/src/commands/up/parachain.rs 7.55% <0.00%> (-0.23%) ⬇️

... and 1 file with indirect coverage changes

@AlexD10S AlexD10S marked this pull request as ready for review July 5, 2024 15:47
@AlexD10S AlexD10S force-pushed the alex/integration-tests branch 2 times, most recently from 0ad326a to e581a18 Compare July 11, 2024 07:48
@AlexD10S AlexD10S merged commit c776588 into main Jul 11, 2024
17 of 18 checks passed
@AlexD10S AlexD10S deleted the alex/integration-tests branch July 11, 2024 10:47
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.

test: integration test for complete contract process Flag to skip user confirmation
3 participants