PIVX Core  5.6.99
P2P Digital Currency
Classes | Macros | Functions
validation_block_tests.cpp File Reference
#include <boost/test/unit_test.hpp>
#include "blockassembler.h"
#include "chainparams.h"
#include "consensus/merkle.h"
#include "consensus/validation.h"
#include "pow.h"
#include "random.h"
#include "test/test_pivx.h"
#include "util/blockstatecatcher.h"
#include "validation.h"
#include "validationinterface.h"
Include dependency graph for validation_block_tests.cpp:

Go to the source code of this file.

Classes

struct  TestSubscriber
 

Macros

#define ASSERT_WITH_MSG(cond, msg)   if (!cond) { BOOST_ERROR(msg); }
 

Functions

std::shared_ptr< CBlockBlock (const uint256 &prev_hash)
 
const std::shared_ptr< const CBlockGoodBlock (const uint256 &prev_hash)
 
const std::shared_ptr< const CBlockBadBlock (const uint256 &prev_hash)
 
void BuildChain (const uint256 &root, int height, const unsigned int invalid_rate, const unsigned int branch_rate, const unsigned int max_size, std::vector< std::shared_ptr< const CBlock >> &blocks)
 
 BOOST_AUTO_TEST_CASE (processnewblock_signals_ordering)
 

Macro Definition Documentation

◆ ASSERT_WITH_MSG

#define ASSERT_WITH_MSG (   cond,
  msg 
)    if (!cond) { BOOST_ERROR(msg); }

Definition at line 19 of file validation_block_tests.cpp.

Function Documentation

◆ BadBlock()

const std::shared_ptr<const CBlock> BadBlock ( const uint256 prev_hash)

Definition at line 77 of file validation_block_tests.cpp.

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

◆ Block()

std::shared_ptr<CBlock> Block ( const uint256 prev_hash)

Definition at line 50 of file validation_block_tests.cpp.

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

◆ BOOST_AUTO_TEST_CASE()

BOOST_AUTO_TEST_CASE ( processnewblock_signals_ordering  )

Definition at line 111 of file validation_block_tests.cpp.

Here is the call graph for this function:

◆ BuildChain()

void BuildChain ( const uint256 root,
int  height,
const unsigned int  invalid_rate,
const unsigned int  branch_rate,
const unsigned int  max_size,
std::vector< std::shared_ptr< const CBlock >> &  blocks 
)

Definition at line 92 of file validation_block_tests.cpp.

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

◆ GoodBlock()

const std::shared_ptr<const CBlock> GoodBlock ( const uint256 prev_hash)

Definition at line 71 of file validation_block_tests.cpp.

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