Skip to content

Fix non stop florestad process in functional tests #434

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

Merged
merged 4 commits into from
Apr 11, 2025

Conversation

qlrd
Copy link
Contributor

@qlrd qlrd commented Mar 31, 2025

Fix #426

What is the purpose of this pull request?

  • Bug fix
  • Documentation update
  • New feature
  • Test
  • Other:

Which crates are being modified?

  • floresta-chain
  • floresta-cli
  • floresta-common
  • floresta-compact-filters
  • floresta-electrum
  • floresta-watch-only
  • floresta-wire
  • floresta
  • florestad
  • Other: functional tests

Description

Added a pipeline for assertions, where a failure of a condition start a node's shutdown procedure. The pipeline can be used with these methods:

  • assertTrue for boolean condition;

  • assertEqual for expected general condition;

  • assertIn for expected item in a list;

  • assertMatch for expected strings in a given regex pattern;

  • assertRaises for expected exceptions.

The pipeline was applied in these suites:

  • Added assertion pipeline to example suite;

  • Added assertion pipeline to floresta-cli suite;

  • Added assertion pipeline to florestad suite.

Notes to the reviewers

This PR depends on #431 to work without false positives.

Checklist

  • I've signed all my commits
  • I ran just lint
  • I ran cargo test
  • I've checked the integration tests
  • I've followed the contribution guidelines
  • I'm linking the issue being fixed by this PR (if any)

@qlrd qlrd changed the title Fix non stop florestad process Fix non stop florestad process in functional tests Mar 31, 2025
Copy link
Collaborator

@Davidson-Souza Davidson-Souza left a comment

Choose a reason for hiding this comment

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

I like the changes, just a few comments.

@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch 2 times, most recently from c3a39ce to 4376c06 Compare April 2, 2025 14:49
@qlrd qlrd requested a review from Davidson-Souza April 2, 2025 15:57
@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch 3 times, most recently from a6efc87 to 1912458 Compare April 3, 2025 12:51
@qlrd
Copy link
Contributor Author

qlrd commented Apr 3, 2025

@jaoleal, can you review 1912458?

@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch 2 times, most recently from fa80b11 to 005fb13 Compare April 4, 2025 17:52
@qlrd qlrd requested review from Davidson-Souza and jaoleal April 5, 2025 13:47
@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch 5 times, most recently from b24d0e4 to eda92cf Compare April 8, 2025 17:28
Copy link
Contributor

@jaoleal jaoleal left a comment

Choose a reason for hiding this comment

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

LGTM, just a thing:

@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch 3 times, most recently from db17b6a to debf6d0 Compare April 8, 2025 22:08
@qlrd qlrd requested a review from jaoleal April 8, 2025 22:19
Copy link
Contributor

@jaoleal jaoleal left a comment

Choose a reason for hiding this comment

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

cACK, could you squash the commits ?

@qlrd
Copy link
Contributor Author

qlrd commented Apr 9, 2025

cACK, could you squash the commits ?

Sure, i was talking right now with @Davidson-Souza about. He requested, however, to keep the commits of each suite separate.

@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch from debf6d0 to a3e64e3 Compare April 9, 2025 14:13
@jaoleal
Copy link
Contributor

jaoleal commented Apr 9, 2025

ACK a3e64e3

Copy link
Collaborator

@Davidson-Souza Davidson-Souza left a comment

Choose a reason for hiding this comment

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

Just one tiny thing and we are good

qlrd added 4 commits April 11, 2025 07:35
Fix vinteumorg#426. The methods below, in addition to performing case assertions,
stop all running nodes if an assertion fails:

* assertTrue for boolean condition;
* assertIsNone for None values;
* assertIsSome for non-None values;
* assertEqual for equality conditions;
* assertIn for expected item in a list;
* assertMatch for expected strings in a given regex pattern;
* assertRaises for expected exceptions.

Update
* addnode;
* getblock;
* getblockchaininfo;
* getblockhash;
* getmemoryinfo;
* getpeerinfo;
* getroots;
* getrpcinfo;
* stop;
* uptime.
* restart;
* ssl (TLS communication with a ssl-enabled node);
* ssl-fail (failure on a TLS communication with non-ssl node).
@qlrd qlrd force-pushed the fix-non-stop-florestad-process branch from a3e64e3 to bcb64d5 Compare April 11, 2025 10:36
@qlrd qlrd requested a review from Davidson-Souza April 11, 2025 10:37
Copy link
Collaborator

@Davidson-Souza Davidson-Souza left a comment

Choose a reason for hiding this comment

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

ACK bcb64d5

@Davidson-Souza Davidson-Souza requested a review from jaoleal April 11, 2025 15:05
@Davidson-Souza Davidson-Souza merged commit 4f12f0e into vinteumorg:master Apr 11, 2025
8 checks passed
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.

[Bug] Florestad do not stop when functional test fail
3 participants