31 context.
args = &test_setup->m_args;
32 context.
chain = test_setup->m_node.chain.get();
45 std::vector<bilingual_str> warnings;
47 auto wallet_path = fs::PathToString(test_setup->m_path_root /
"test_wallet");
49 auto wallet =
CreateWallet(context, wallet_path, std::nullopt, options, status, error_string, warnings);
56 fs::remove_all(wallet_path);
uint256 rand256() noexcept
generate a random uint256.
Main entry point to nanobench's benchmarking facility.
Bench & run(char const *benchmarkName, Op &&op)
Repeatedly calls op() based on the configuration, and performs measurements.
std::string ToString() const
static void WalletCreate(benchmark::Bench &bench, bool encrypted)
std::shared_ptr< CWallet > CreateWallet(WalletContext &context, const std::string &name, std::optional< bool > load_on_start, DatabaseOptions &options, DatabaseStatus &status, bilingual_str &error, std::vector< bilingual_str > &warnings)
@ WALLET_FLAG_DESCRIPTORS
Indicate that this wallet supports DescriptorScriptPubKeyMan.
void WaitForDeleteWallet(std::shared_ptr< CWallet > &&wallet)
static void WalletCreatePlain(benchmark::Bench &bench)
bool RemoveWallet(WalletContext &context, const std::shared_ptr< CWallet > &wallet, std::optional< bool > load_on_start, std::vector< bilingual_str > &warnings)
static void WalletCreateEncrypted(benchmark::Bench &bench)
std::unique_ptr< T > MakeNoLogFileContext(const ChainType chain_type=ChainType::REGTEST, TestOpts opts={})
Make a test setup that has disk access to the debug.log file disabled.
SecureString create_passphrase
std::optional< DatabaseFormat > require_format
interfaces::Chain * chain