Skip to content

Commit

Permalink
add simtest
Browse files Browse the repository at this point in the history
  • Loading branch information
mwtian committed Dec 6, 2024
1 parent 0e629ba commit 33c511f
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions crates/sui-benchmark/tests/simtest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ mod test {
LocalValidatorAggregatorProxy, ValidatorProxy,
};
use sui_config::node::AuthorityOverloadConfig;
use sui_config::{ExecutionCacheConfig, AUTHORITIES_DB_NAME, SUI_KEYSTORE_FILENAME};
use sui_config::{AUTHORITIES_DB_NAME, SUI_KEYSTORE_FILENAME};
use sui_core::authority::authority_store_tables::AuthorityPerpetualTables;
use sui_core::authority::framework_injection;
use sui_core::authority::AuthorityState;
Expand Down Expand Up @@ -173,13 +173,10 @@ mod test {
test_cluster.wait_for_epoch_all_nodes(1).await;
}

#[ignore("Disabled due to flakiness - re-enable when failure is fixed")]
#[sim_test(config = "test_config()")]
async fn test_simulated_load_reconfig_restarts() {
// TODO added to invalidate a failing test seed in CI. Remove me
tokio::time::sleep(Duration::from_secs(1)).await;
sui_protocol_config::ProtocolConfig::poison_get_for_min_version();
let test_cluster = build_test_cluster(4, 1000, 1).await;
let test_cluster = build_test_cluster(4, 5_000, 1).await;
let node_restarter = test_cluster
.random_node_restarter()
.with_kill_interval_secs(5, 15)
Expand All @@ -188,6 +185,13 @@ mod test {
test_simulated_load(test_cluster, 120).await;
}

#[sim_test(config = "test_config()")]
async fn test_simulated_load_small_committee_reconfig() {
sui_protocol_config::ProtocolConfig::poison_get_for_min_version();
let test_cluster = build_test_cluster(1, 5_000, 0).await;
test_simulated_load(test_cluster, 120).await;
}

/// Get a list of nodes that we don't want to kill in the crash recovery tests.
/// This includes the client node which is the node that is running the test, as well as
/// rpc fullnode which are needed to run the benchmark.
Expand Down

0 comments on commit 33c511f

Please sign in to comment.