mirror of
https://github.com/jwinterm/grin-wallet.git
synced 2026-10-17 15:21:39 +02:00
set_local_chain_type in owner and foreign tests
This commit is contained in:
+3
-2
@@ -121,7 +121,7 @@ where
|
||||
/// use impls::{DefaultWalletImpl, DefaultLCProvider, HTTPNodeClient};
|
||||
/// use libwallet::WalletInst;
|
||||
///
|
||||
/// global::init_global_chain_type(global::ChainTypes::Mainnet);
|
||||
/// global::set_local_chain_type(global::ChainTypes::AutomatedTesting);
|
||||
///
|
||||
/// let mut wallet_config = WalletConfig::default();
|
||||
/// # let dir = tempdir().map_err(|e| format!("{:#?}", e)).unwrap();
|
||||
@@ -427,7 +427,8 @@ macro_rules! doctest_helper_setup_doc_env_foreign {
|
||||
use impls::{DefaultLCProvider, DefaultWalletImpl, HTTPNodeClient};
|
||||
use libwallet::{BlockFees, IssueInvoiceTxArgs, Slate, WalletInst};
|
||||
|
||||
global::init_global_chain_type(global::ChainTypes::Mainnet);
|
||||
// Set our local chain_type for testing.
|
||||
global::set_local_chain_type(global::ChainTypes::AutomatedTesting);
|
||||
|
||||
let dir = tempdir().map_err(|e| format!("{:#?}", e)).unwrap();
|
||||
let dir = dir
|
||||
|
||||
+3
-4
@@ -127,7 +127,7 @@ where
|
||||
/// use impls::{DefaultWalletImpl, DefaultLCProvider, HTTPNodeClient};
|
||||
/// use libwallet::WalletInst;
|
||||
///
|
||||
/// global::init_global_chain_type(global::ChainTypes::Mainnet);
|
||||
/// global::set_local_chain_type(global::ChainTypes::AutomatedTesting);
|
||||
///
|
||||
/// let mut wallet_config = WalletConfig::default();
|
||||
/// # let dir = tempdir().map_err(|e| format!("{:#?}", e)).unwrap();
|
||||
@@ -2132,9 +2132,8 @@ macro_rules! doctest_helper_setup_doc_env {
|
||||
|
||||
use uuid::Uuid;
|
||||
|
||||
// Various levels of magic going on in these doctests and we need to ensure
|
||||
// the global chain_type is set correctly.
|
||||
global::init_global_chain_type(global::ChainTypes::Mainnet);
|
||||
// Set our local chain_type for testing.
|
||||
global::set_local_chain_type(global::ChainTypes::AutomatedTesting);
|
||||
|
||||
let dir = tempdir().map_err(|e| format!("{:#?}", e)).unwrap();
|
||||
let dir = dir
|
||||
|
||||
Reference in New Issue
Block a user