PIVX Core  5.6.99
P2P Digital Currency
Functions
sapling_wallet_tests.cpp File Reference
#include "wallet/test/wallet_test_fixture.h"
#include <sodium.h>
#include "chainparams.h"
#include "key_io.h"
#include "validation.h"
#include "optional.h"
#include "primitives/block.h"
#include "random.h"
#include "sapling/transaction_builder.h"
#include "test/librust/utiltest.h"
#include "wallet/wallet.h"
#include "consensus/merkle.h"
#include "sapling/note.h"
#include "sapling/noteencryption.h"
#include <boost/filesystem.hpp>
#include <boost/test/unit_test.hpp>
Include dependency graph for sapling_wallet_tests.cpp:

Go to the source code of this file.

Functions

void setupWallet (CWallet &wallet)
 
std::vector< SaplingOutPointSetSaplingNoteData (CWalletTx &wtx)
 
SaplingOutPoint CreateValidBlock (CWallet &wallet, libzcash::SaplingExtendedSpendingKey &sk, const CBlockIndex &index, CBlock &block, SaplingMerkleTree &saplingTree)
 
uint256 GetWitnessesAndAnchors (CWallet &wallet, const std::vector< SaplingOutPoint > &saplingNotes, std::vector< Optional< SaplingWitness >> &saplingWitnesses)
 
 BOOST_AUTO_TEST_CASE (SetSaplingNoteAddrsInCWalletTx)
 
 BOOST_AUTO_TEST_CASE (SetInvalidSaplingNoteDataInCWalletTx)
 
 BOOST_AUTO_TEST_CASE (FindMySaplingNotes)
 
 BOOST_AUTO_TEST_CASE (GetConflictedSaplingNotes)
 
 BOOST_AUTO_TEST_CASE (SaplingNullifierIsSpent)
 
 BOOST_AUTO_TEST_CASE (NavigateFromSaplingNullifierToNote)
 
 BOOST_AUTO_TEST_CASE (SpentSaplingNoteIsFromMe)
 
 BOOST_AUTO_TEST_CASE (CachedWitnessesEmptyChain)
 
 BOOST_AUTO_TEST_CASE (CachedWitnessesChainTip)
 
 BOOST_AUTO_TEST_CASE (CachedWitnessesDecrementFirst)
 
 BOOST_AUTO_TEST_CASE (CachedWitnessesCleanIndex)
 
 BOOST_AUTO_TEST_CASE (ClearNoteWitnessCache)
 
 BOOST_AUTO_TEST_CASE (UpdatedSaplingNoteData)
 
 BOOST_AUTO_TEST_CASE (MarkAffectedSaplingTransactionsDirty)
 
 BOOST_AUTO_TEST_CASE (GetNotes)
 

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/15]

BOOST_AUTO_TEST_CASE ( CachedWitnessesChainTip  )

Definition at line 638 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [2/15]

BOOST_AUTO_TEST_CASE ( CachedWitnessesCleanIndex  )

Definition at line 786 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [3/15]

BOOST_AUTO_TEST_CASE ( CachedWitnessesDecrementFirst  )

Definition at line 718 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [4/15]

BOOST_AUTO_TEST_CASE ( CachedWitnessesEmptyChain  )

Definition at line 598 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [5/15]

BOOST_AUTO_TEST_CASE ( ClearNoteWitnessCache  )

Definition at line 863 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [6/15]

BOOST_AUTO_TEST_CASE ( FindMySaplingNotes  )

Definition at line 141 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [7/15]

BOOST_AUTO_TEST_CASE ( GetConflictedSaplingNotes  )

Definition at line 178 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [8/15]

BOOST_AUTO_TEST_CASE ( GetNotes  )

Definition at line 1133 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [9/15]

BOOST_AUTO_TEST_CASE ( MarkAffectedSaplingTransactionsDirty  )

Definition at line 1023 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [10/15]

BOOST_AUTO_TEST_CASE ( NavigateFromSaplingNullifierToNote  )

Definition at line 357 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [11/15]

BOOST_AUTO_TEST_CASE ( SaplingNullifierIsSpent  )

Definition at line 298 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [12/15]

BOOST_AUTO_TEST_CASE ( SetInvalidSaplingNoteDataInCWalletTx  )

Definition at line 129 of file sapling_wallet_tests.cpp.

◆ BOOST_AUTO_TEST_CASE() [13/15]

BOOST_AUTO_TEST_CASE ( SetSaplingNoteAddrsInCWalletTx  )

Definition at line 74 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [14/15]

BOOST_AUTO_TEST_CASE ( SpentSaplingNoteIsFromMe  )

Definition at line 453 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [15/15]

BOOST_AUTO_TEST_CASE ( UpdatedSaplingNoteData  )

Definition at line 912 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:

◆ CreateValidBlock()

SaplingOutPoint CreateValidBlock ( CWallet wallet,
libzcash::SaplingExtendedSpendingKey sk,
const CBlockIndex index,
CBlock block,
SaplingMerkleTree saplingTree 
)

Definition at line 45 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetWitnessesAndAnchors()

uint256 GetWitnessesAndAnchors ( CWallet wallet,
const std::vector< SaplingOutPoint > &  saplingNotes,
std::vector< Optional< SaplingWitness >> &  saplingWitnesses 
)

Definition at line 62 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetSaplingNoteData()

std::vector<SaplingOutPoint> SetSaplingNoteData ( CWalletTx wtx)

Definition at line 33 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setupWallet()

void setupWallet ( CWallet wallet)

Definition at line 27 of file sapling_wallet_tests.cpp.

Here is the call graph for this function:
Here is the caller graph for this function: