diff --git a/explorer/src/api/graphql/mod.rs b/explorer/src/api/graphql/mod.rs index 7894eb8aed..f0df96e4bc 100644 --- a/explorer/src/api/graphql/mod.rs +++ b/explorer/src/api/graphql/mod.rs @@ -1314,11 +1314,7 @@ impl VotePlanStatus { return Ok(Self::vote_plan_from_data(vote_plan)); } - Err(ApiError::NotFound(format!( - "Vote plan with id {} not found", - vote_plan_id.to_string() - )) - .into()) + Err(ApiError::NotFound(format!("Vote plan with id {} not found", vote_plan_id)).into()) } pub fn vote_plan_from_data(vote_plan: Arc) -> Self { diff --git a/testing/jormungandr-automation/src/jormungandr/explorer/mod.rs b/testing/jormungandr-automation/src/jormungandr/explorer/mod.rs index a4b87083cb..4f9c7ad8d0 100644 --- a/testing/jormungandr-automation/src/jormungandr/explorer/mod.rs +++ b/testing/jormungandr-automation/src/jormungandr/explorer/mod.rs @@ -1,4 +1,4 @@ -use crate::testing::configuration::{get_available_port, get_explorer_app}; +use crate::testing::configuration::get_explorer_app; use self::{ client::GraphQlClient, @@ -34,6 +34,8 @@ use std::path::Path; use std::path::PathBuf; use thiserror::Error; +use super::get_available_port; + #[derive(Error, Debug)] pub enum ExplorerError { #[error("graph client error")] diff --git a/testing/jormungandr-automation/src/jormungandr/process.rs b/testing/jormungandr-automation/src/jormungandr/process.rs index dbbbea962e..9f6081fcf9 100644 --- a/testing/jormungandr-automation/src/jormungandr/process.rs +++ b/testing/jormungandr-automation/src/jormungandr/process.rs @@ -323,8 +323,8 @@ impl JormungandrProcess { .unwrap(); TimeEra::new( - (block_date.slot_id as u64).into(), - chain_time::Epoch(block_date.epoch), + (block_date.slot() as u64).into(), + chain_time::Epoch(block_date.epoch()), self.block0_configuration .blockchain_configuration .slots_per_epoch diff --git a/testing/jormungandr-integration-tests/src/jormungandr/explorer.rs b/testing/jormungandr-integration-tests/src/jormungandr/explorer.rs index 2293f79be6..07865ab668 100644 --- a/testing/jormungandr-integration-tests/src/jormungandr/explorer.rs +++ b/testing/jormungandr-integration-tests/src/jormungandr/explorer.rs @@ -10,6 +10,7 @@ use jormungandr_lib::interfaces::ActiveSlotCoefficient; use jortestkit::process::Wait; use std::str::FromStr; use std::time::Duration; +use thor::{StakePool, TransactionHash}; /// test checks if there is upto date schema /// prereq: diff --git a/testing/jormungandr-integration-tests/src/jormungandr/fragments.rs b/testing/jormungandr-integration-tests/src/jormungandr/fragments.rs index 218f4d7d4f..0372f44779 100644 --- a/testing/jormungandr-integration-tests/src/jormungandr/fragments.rs +++ b/testing/jormungandr-integration-tests/src/jormungandr/fragments.rs @@ -12,8 +12,6 @@ pub fn send_all_fragments() { let receiver = thor::Wallet::default(); let sender = thor::Wallet::default(); - dbg!("starting stake pool"); - let (jormungandr, _) = startup::start_stake_pool( &[sender.clone()], &[receiver.clone()], @@ -34,18 +32,11 @@ pub fn send_all_fragments() { let fragment_sender = FragmentSender::from_with_setup( jormungandr.block0_configuration(), - jormungandr.genesis_block_hash(), - jormungandr.fees(), - jormungandr.default_block_date_generator(), FragmentSenderSetup::no_verify(), ); - dbg!("fragment sender built"); - let time_era = jormungandr.time_era(); - dbg!("time era"); - let mut fragment_generator = FragmentGenerator::new( sender, receiver, @@ -57,17 +48,12 @@ pub fn send_all_fragments() { fragment_sender, ); - dbg!("generating fragments"); - fragment_generator.prepare(BlockDate::new(1, 0)); - dbg!("waiting for epoch"); - time::wait_for_epoch(2, jormungandr.rest()); let mem_checks: Vec = fragment_generator.send_all().unwrap(); - dbg!("wait and verify"); FragmentVerifier::wait_and_verify_all_are_in_block( Duration::from_secs(2), mem_checks, diff --git a/testing/jormungandr-integration-tests/src/networking/explorer.rs b/testing/jormungandr-integration-tests/src/networking/explorer.rs index 0311dd6c7d..bc96dc02d5 100644 --- a/testing/jormungandr-integration-tests/src/networking/explorer.rs +++ b/testing/jormungandr-integration-tests/src/networking/explorer.rs @@ -6,7 +6,6 @@ use hersir::builder::SpawnParams; use hersir::builder::Topology; use jormungandr_automation::testing::time; use jormungandr_lib::interfaces::BlockDate; -use jormungandr_lib::interfaces::Explorer; use thor::FragmentSender; const LEADER_1: &str = "Leader_1"; const LEADER_2: &str = "Leader_2"; diff --git a/testing/jormungandr-integration-tests/src/networking/stake_pool/retire.rs b/testing/jormungandr-integration-tests/src/networking/stake_pool/retire.rs index a52f37efbb..44b57eceea 100644 --- a/testing/jormungandr-integration-tests/src/networking/stake_pool/retire.rs +++ b/testing/jormungandr-integration-tests/src/networking/stake_pool/retire.rs @@ -6,7 +6,6 @@ use hersir::builder::SpawnParams; use hersir::builder::Topology; use jormungandr_automation::testing::time; use jormungandr_lib::interfaces::BlockDate; -use jormungandr_lib::interfaces::Explorer; use thor::FragmentSender; const LEADER_1: &str = "Leader_1"; const LEADER_2: &str = "Leader_2";