Cleanup local cluster (#6897)
* Boot integration tests from unit test build * Move bench-tps and bench-exchange integration tests out of local_cluster * Fix build
This commit is contained in:
parent
48987bed67
commit
81acd94153
|
@ -3041,6 +3041,7 @@ dependencies = [
|
|||
"solana-exchange-api 0.21.0",
|
||||
"solana-exchange-program 0.21.0",
|
||||
"solana-genesis 0.21.0",
|
||||
"solana-local-cluster 0.21.0",
|
||||
"solana-logger 0.21.0",
|
||||
"solana-metrics 0.21.0",
|
||||
"solana-net-utils 0.21.0",
|
||||
|
@ -3079,6 +3080,7 @@ dependencies = [
|
|||
"solana-drone 0.21.0",
|
||||
"solana-genesis 0.21.0",
|
||||
"solana-librapay-api 0.21.0",
|
||||
"solana-local-cluster 0.21.0",
|
||||
"solana-logger 0.21.0",
|
||||
"solana-measure 0.21.0",
|
||||
"solana-metrics 0.21.0",
|
||||
|
@ -3621,8 +3623,6 @@ dependencies = [
|
|||
"rand 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"serial_test 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"serial_test_derive 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
|
||||
"solana-bench-exchange 0.21.0",
|
||||
"solana-bench-tps 0.21.0",
|
||||
"solana-client 0.21.0",
|
||||
"solana-config-api 0.21.0",
|
||||
"solana-core 0.21.0",
|
||||
|
@ -3632,8 +3632,6 @@ dependencies = [
|
|||
"solana-genesis-programs 0.21.0",
|
||||
"solana-ledger 0.21.0",
|
||||
"solana-logger 0.21.0",
|
||||
"solana-move-loader-api 0.21.0",
|
||||
"solana-move-loader-program 0.21.0",
|
||||
"solana-rayon-threadlimit 0.21.0",
|
||||
"solana-runtime 0.21.0",
|
||||
"solana-sdk 0.21.0",
|
||||
|
|
|
@ -37,3 +37,6 @@ solana-runtime = { path = "../runtime", version = "0.21.0" }
|
|||
solana-sdk = { path = "../sdk", version = "0.21.0" }
|
||||
untrusted = "0.7.0"
|
||||
ws = "0.9.1"
|
||||
|
||||
[dev-dependencies]
|
||||
solana-local-cluster = { path = "../local_cluster", version = "0.21.0" }
|
||||
|
|
|
@ -1,10 +1,12 @@
|
|||
use crate::local_cluster::{ClusterConfig, LocalCluster};
|
||||
use log::*;
|
||||
use solana_bench_exchange::bench::{airdrop_lamports, do_bench_exchange, Config};
|
||||
use solana_core::gossip_service::{discover_cluster, get_multi_client};
|
||||
use solana_core::validator::ValidatorConfig;
|
||||
use solana_drone::drone::run_local_drone;
|
||||
use solana_exchange_api::exchange_processor::process_instruction;
|
||||
use solana_exchange_api::id;
|
||||
use solana_exchange_program::solana_exchange_program;
|
||||
use solana_local_cluster::local_cluster::{ClusterConfig, LocalCluster};
|
||||
use solana_runtime::bank::Bank;
|
||||
use solana_runtime::bank_client::BankClient;
|
||||
use solana_sdk::genesis_config::create_genesis_config;
|
|
@ -33,6 +33,7 @@ solana-move-loader-api = { path = "../programs/move_loader_api", version = "0.21
|
|||
[dev-dependencies]
|
||||
serial_test = "0.2.0"
|
||||
serial_test_derive = "0.2.0"
|
||||
solana-local-cluster = { path = "../local_cluster", version = "0.21.0" }
|
||||
|
||||
[features]
|
||||
move = ["solana-librapay-api", "solana-move-loader-program", "solana-move-loader-api"]
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
use crate::local_cluster::{ClusterConfig, LocalCluster};
|
||||
use serial_test_derive::serial;
|
||||
use solana_bench_tps::bench::{do_bench_tps, generate_and_fund_keypairs};
|
||||
use solana_bench_tps::cli::Config;
|
||||
|
@ -6,6 +5,7 @@ use solana_client::thin_client::create_client;
|
|||
use solana_core::cluster_info::VALIDATOR_PORT_RANGE;
|
||||
use solana_core::validator::ValidatorConfig;
|
||||
use solana_drone::drone::run_local_drone;
|
||||
use solana_local_cluster::local_cluster::{ClusterConfig, LocalCluster};
|
||||
#[cfg(feature = "move")]
|
||||
use solana_sdk::move_loader::solana_move_loader_program;
|
||||
use solana_sdk::signature::{Keypair, KeypairUtil};
|
|
@ -32,7 +32,7 @@ echo "Executing $testName"
|
|||
case $testName in
|
||||
test-stable)
|
||||
_ cargo +"$rust_stable" test --all --exclude solana-local-cluster ${V:+--verbose} -- --nocapture
|
||||
_ cargo +"$rust_stable" test --manifest-path local_cluster/Cargo.toml --features=move ${V:+--verbose} test_bench_tps_local_cluster_move -- --nocapture
|
||||
_ cargo +"$rust_stable" test --manifest-path bench-tps/Cargo.toml --features=move ${V:+--verbose} test_bench_tps_local_cluster_move -- --nocapture
|
||||
;;
|
||||
test-stable-perf)
|
||||
ci/affects-files.sh \
|
||||
|
|
|
@ -11,8 +11,6 @@ homepage = "https://solana.com/"
|
|||
[dependencies]
|
||||
log = "0.4.8"
|
||||
rand = "0.6.5"
|
||||
solana-bench-exchange = { path = "../bench-exchange", version = "0.21.0" }
|
||||
solana-bench-tps = { path = "../bench-tps", version = "0.21.0" }
|
||||
solana-config-api = { path = "../programs/config_api", version = "0.21.0" }
|
||||
solana-core = { path = "../core", version = "0.21.0" }
|
||||
solana-client = { path = "../client", version = "0.21.0" }
|
||||
|
@ -22,8 +20,6 @@ solana-exchange-program = { path = "../programs/exchange_program", version = "0.
|
|||
solana-genesis-programs = { path = "../genesis_programs", version = "0.21.0" }
|
||||
solana-ledger = { path = "../ledger", version = "0.21.0" }
|
||||
solana-logger = { path = "../logger", version = "0.21.0" }
|
||||
solana-move-loader-api = { path = "../programs/move_loader_api", version = "0.21.0", optional = true }
|
||||
solana-move-loader-program = { path = "../programs/move_loader_program", version = "0.21.0", optional = true }
|
||||
solana-runtime = { path = "../runtime", version = "0.21.0" }
|
||||
solana-sdk = { path = "../sdk", version = "0.21.0" }
|
||||
solana-stake-api = { path = "../programs/stake_api", version = "0.21.0" }
|
||||
|
@ -38,6 +34,3 @@ solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "0.21.0" }
|
|||
[dev-dependencies]
|
||||
serial_test = "0.2.0"
|
||||
serial_test_derive = "0.2.0"
|
||||
|
||||
[features]
|
||||
move = ["solana-bench-tps/move", "solana-move-loader-api", "solana-move-loader-program"]
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
use log::*;
|
||||
/// Cluster independant integration tests
|
||||
///
|
||||
/// All tests must start from an entry point and a funding keypair and
|
||||
|
|
|
@ -1,40 +1,9 @@
|
|||
#[cfg(test)]
|
||||
mod cluster;
|
||||
#[cfg(test)]
|
||||
mod cluster_tests;
|
||||
#[cfg(test)]
|
||||
mod local_cluster;
|
||||
#[cfg(test)]
|
||||
mod tests;
|
||||
pub mod cluster;
|
||||
pub mod cluster_tests;
|
||||
pub mod local_cluster;
|
||||
|
||||
#[macro_use]
|
||||
#[cfg(test)]
|
||||
extern crate log;
|
||||
|
||||
#[cfg(test)]
|
||||
extern crate solana_bench_exchange;
|
||||
|
||||
#[cfg(test)]
|
||||
extern crate solana_bench_tps;
|
||||
|
||||
#[macro_use]
|
||||
#[cfg(test)]
|
||||
extern crate solana_ledger;
|
||||
|
||||
#[cfg(test)]
|
||||
extern crate solana_drone;
|
||||
|
||||
#[macro_use]
|
||||
#[cfg(test)]
|
||||
extern crate solana_exchange_program;
|
||||
|
||||
#[cfg(feature = "move")]
|
||||
#[cfg(test)]
|
||||
extern crate solana_move_loader_program;
|
||||
|
||||
#[macro_use]
|
||||
#[cfg(test)]
|
||||
extern crate solana_storage_program;
|
||||
|
||||
#[cfg(test)]
|
||||
extern crate tempfile;
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
use crate::cluster::{Cluster, ClusterValidatorInfo, ValidatorInfo};
|
||||
use log::*;
|
||||
use solana_client::thin_client::{create_client, ThinClient};
|
||||
use solana_core::{
|
||||
archiver::Archiver,
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
mod archiver;
|
||||
mod bench_exchange;
|
||||
mod bench_tps;
|
||||
mod local_cluster;
|
|
@ -1,4 +1,7 @@
|
|||
use crate::local_cluster::{ClusterConfig, LocalCluster};
|
||||
#[macro_use]
|
||||
extern crate solana_ledger;
|
||||
|
||||
use log::*;
|
||||
use serial_test_derive::serial;
|
||||
use solana_client::thin_client::create_client;
|
||||
use solana_core::{
|
||||
|
@ -10,6 +13,7 @@ use solana_core::{
|
|||
validator::ValidatorConfig,
|
||||
};
|
||||
use solana_ledger::blocktree::{create_new_tmp_ledger, get_tmp_ledger_path, Blocktree};
|
||||
use solana_local_cluster::local_cluster::{ClusterConfig, LocalCluster};
|
||||
use solana_sdk::{
|
||||
commitment_config::CommitmentConfig,
|
||||
genesis_config::create_genesis_config,
|
|
@ -1,8 +1,3 @@
|
|||
use crate::{
|
||||
cluster::Cluster,
|
||||
cluster_tests,
|
||||
local_cluster::{ClusterConfig, LocalCluster},
|
||||
};
|
||||
use log::*;
|
||||
use serial_test_derive::serial;
|
||||
use solana_client::thin_client::create_client;
|
||||
|
@ -11,6 +6,11 @@ use solana_core::{
|
|||
gossip_service::discover_cluster, validator::ValidatorConfig,
|
||||
};
|
||||
use solana_ledger::{bank_forks::SnapshotConfig, blocktree::Blocktree, snapshot_utils};
|
||||
use solana_local_cluster::{
|
||||
cluster::Cluster,
|
||||
cluster_tests,
|
||||
local_cluster::{ClusterConfig, LocalCluster},
|
||||
};
|
||||
use solana_runtime::accounts_db::AccountsDB;
|
||||
use solana_sdk::{
|
||||
client::SyncClient,
|
Loading…
Reference in New Issue