diff --git a/cmd/replay/src/main.rs b/cmd/replay/src/main.rs index 896d0c2f98..c0c6a9ba80 100644 --- a/cmd/replay/src/main.rs +++ b/cmd/replay/src/main.rs @@ -49,10 +49,7 @@ fn main() -> anyhow::Result<()> { let _logger = starcoin_logger::init(); let opts: ReplayOpt = ReplayOpt::parse(); - let network = match opts.net { - Some(network) => network, - None => BuiltinNetworkID::Proxima, - }; + let network = opts.net.unwrap_or(BuiltinNetworkID::Proxima); let net = ChainNetwork::new_builtin(network); let from_dir = opts.from; diff --git a/config/src/lib.rs b/config/src/lib.rs index 87320ca097..868f8b6dd2 100644 --- a/config/src/lib.rs +++ b/config/src/lib.rs @@ -484,15 +484,6 @@ impl NodeConfig { Self::load_with_opt(&opt).expect("Auto generate test config should success.") } - pub fn proxima_for_test(dir: PathBuf) -> Self { - let opt = StarcoinOpt { - net: Some(BuiltinNetworkID::Proxima.into()), - base_data_dir: Some(dir), - ..StarcoinOpt::default() - }; - Self::load_with_opt(&opt).expect("Auto generate proxima config should success.") - } - pub fn customize_for_test() -> Self { let opt = StarcoinOpt { net: Some(BuiltinNetworkID::Test.into()), diff --git a/sync/src/tasks/tests.rs b/sync/src/tasks/tests.rs index d6a24ed9cc..f023da088e 100644 --- a/sync/src/tasks/tests.rs +++ b/sync/src/tasks/tests.rs @@ -107,7 +107,8 @@ pub async fn test_sync_invalid_target() -> Result<()> { #[stest::test] pub async fn test_failed_block() -> Result<()> { - let net = ChainNetwork::new_builtin(BuiltinNetworkID::Halley); + // todo: fix this test for dag chain (dag effective height is ZERO) + let net = ChainNetwork::new_builtin(BuiltinNetworkID::Test); let (storage, chain_info, _, dag) = Genesis::init_storage_for_test(&net)?; let chain = BlockChain::new(