LCOV - code coverage report
Current view: top level - src/wallet/test - wallet_test_fixture.h (source / functions) Hit Total Coverage
Test: total_coverage.info Lines: 2 2 100.0 %
Date: 2020-09-26 01:30:44 Functions: 2 2 100.0 %

          Line data    Source code
       1             : // Copyright (c) 2016-2020 The Bitcoin Core developers
       2             : // Distributed under the MIT software license, see the accompanying
       3             : // file COPYING or http://www.opensource.org/licenses/mit-license.php.
       4             : 
       5             : #ifndef BITCOIN_WALLET_TEST_WALLET_TEST_FIXTURE_H
       6             : #define BITCOIN_WALLET_TEST_WALLET_TEST_FIXTURE_H
       7             : 
       8             : #include <test/util/setup_common.h>
       9             : 
      10             : #include <interfaces/chain.h>
      11             : #include <interfaces/wallet.h>
      12             : #include <node/context.h>
      13             : #include <util/check.h>
      14             : #include <wallet/wallet.h>
      15             : 
      16             : #include <memory>
      17             : 
      18             : /** Testing setup and teardown for wallet.
      19             :  */
      20           9 : struct WalletTestingSetup : public TestingSetup {
      21             :     explicit WalletTestingSetup(const std::string& chainName = CBaseChainParams::MAIN);
      22             : 
      23             :     std::unique_ptr<interfaces::Chain> m_chain = interfaces::MakeChain(m_node);
      24           9 :     std::unique_ptr<interfaces::WalletClient> m_wallet_client = interfaces::MakeWalletClient(*m_chain, *Assert(m_node.args), {});
      25             :     CWallet m_wallet;
      26             :     std::unique_ptr<interfaces::Handler> m_chain_notifications_handler;
      27             : };
      28             : 
      29             : #endif // BITCOIN_WALLET_TEST_WALLET_TEST_FIXTURE_H

Generated by: LCOV version 1.15