logos-blockchain-testing/examples/doc-snippets/src/dsl_cheat_sheet_build_complete_example.rs
Hansie Odendaal dc06af5486
update for main repo changes (#10)
Update for main repo changes - this implied many changes in the testing framework code

removal of DA config-related code that was still present because it was required by node code until now
nomos-da-network-core = { workspace = true }
subnetworks-assignations = { workspace = true }
nomos-da-dispersal = { workspace = true }
nomos-da-network-core = { workspace = true }
nomos-da-network-service = { workspace = true }
nomos-da-sampling = { workspace = true }
nomos-da-verifier = { workspace = true }
nomos-ledger = { workspace = true, features = ["serde"] }
removal of the executor node
logos-blockchain-executor = { workspace = true }
2026-01-25 10:11:16 +02:00

25 lines
754 B
Rust

use std::time::Duration;
use anyhow::Result;
use testing_framework_core::scenario::{Deployer, ScenarioBuilder};
use testing_framework_runner_local::LocalDeployer;
use testing_framework_workflows::ScenarioBuilderExt;
pub async fn run_test() -> Result<()> {
let mut plan = ScenarioBuilder::topology_with(|t| t.network_star().validators(3))
.wallets(50)
.transactions_with(|txs| {
txs.rate(5) // 5 transactions per block
.users(20)
})
.expect_consensus_liveness()
.with_run_duration(Duration::from_secs(90))
.build()?;
let deployer = LocalDeployer::default();
let runner = deployer.deploy(&plan).await?;
let _handle = runner.run(&mut plan).await?;
Ok(())
}