Skip to content

Conversation

@Sophie-Ag00001
Copy link
Collaborator

PR Description: Refactor Tests to Focus on Single Node Setup

Summary of Changes

This PR removes tests that involve multi-node setups while retaining only those that operate on a single node. Specifically, tests with the following patterns have been removed:

  • "*_2_nodes"
  • "*_3_nodes"
  • "*_15_nodes"
  • "*majority_3_nodes"
  • "*majority_15_nodes"
  • "*_multi_miners_raft_2_nodes"

Additionally, the following specific multi-node functions have been deleted:

  • full_flow_raft_2_nodes
  • full_flow_raft_3_nodes
  • full_flow_raft_majority_3_nodes
  • full_flow_raft_majority_15_nodes
  • full_flow_multi_miners_raft_2_nodes
  • full_flow_raft_kill_forever_*_node_3_nodes
  • full_flow_raft_kill_*_node_3_nodes
  • full_flow_raft_dis_and_re_connect_*_node_3_nodes

The focus has been maintained on keeping single node tests, such as:

  • All _1_node tests
  • Tests with no_raft
  • Tests named _raft_real_db_1_node

Motivation

The primary motivation behind this change is to streamline the testing process by eliminating unnecessary complexity associated with multi-node communications. Concentrating on single node testing ensures more straightforward debugging and more efficient use of resources during testing.

Relevant Context

This refactor is part of an ongoing effort to enhance testing clarity and efficiency. By maintaining a clear separation between single and multi-node tests, we aim to facilitate better maintenance and understanding of test outcomes.

Instructions for Testing Changes

  1. Ensure all tests pertaining to single node functionality are passing by running cargo test in the tests.rs file.
  2. Review the logs to confirm that no multi-node tests are executed.
  3. Verify that the retained tests adequately cover the required functionality.

Known Issues or Limitations

There are no known issues following this change. This refactor strictly adheres to the specified requirements of only altering tests.rs without impacting other files.


Feel free to reach out if you have any questions or require further clarification on the modifications made!

"*_2_nodes"
"*_3_nodes"
"*_15_nodes"
"*majority_3_nodes"
"*majority_15_nodes"
"*_multi_miners_raft_2_nodes"

Keep single node tests:

Keep all "_1_node" tests
Keep "no_raft" tests
Keep "_raft_real_db_1_node" tests

Remove these specific multi-node functions:

full_flow_raft_2_nodes
full_flow_raft_3_nodes
full_flow_raft_majority_3_nodes
full_flow_raft_majority_15_nodes
full_flow_multi_miners_raft_2_nodes
full_flow_raft_kill_forever_*_node_3_nodes
full_flow_raft_kill_*_node_3_nodes
full_flow_raft_dis_and_re_connect_*_node_3_nodes

The goal is to only keep tests that operate on a single node setup. All tests involving multiple nodes communicating with each other should be removed. ONLY work on tests.rs, DO NOT edit any other files
@Sophie-Ag00001 Sophie-Ag00001 requested a review from a team as a code owner January 9, 2025 06:58
@BHouwens BHouwens closed this Jan 9, 2025
@BHouwens BHouwens deleted the task/remove-tests-patterns-name branch January 9, 2025 07:01
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.

3 participants