Fabcoin Core  0.16.2
P2P Digital Currency
Functions | Variables
difficulty.cpp File Reference
#include <boost/test/unit_test.hpp>
#include <test/libtesteth/TestHelper.h>
#include <test/fuzzTesting/fuzzHelper.h>
#include <libethashseal/Ethash.h>
#include <libethashseal/GenesisInfo.h>
#include <libethereum/ChainParams.h>
Include dependency graph for difficulty.cpp:

Go to the source code of this file.

Functions

void checkCalculatedDifficulty (BlockHeader const &_bi, BlockHeader const &_parent, Network _n, ChainOperationParams const &_p, string const &_testName="")
 
void fillDifficulty (string const &_testFileFullName, Ethash &_sealEngine)
 
void testDifficulty (string const &_testFileFullName, Ethash &_sealEngine, Network _n)
 
 BOOST_AUTO_TEST_CASE (difficultyTestsFrontier)
 
 BOOST_AUTO_TEST_CASE (difficultyTestsRopsten)
 
 BOOST_AUTO_TEST_CASE (difficultyTestsHomestead)
 
 BOOST_AUTO_TEST_CASE (difficultyTestsMainNetwork)
 
 BOOST_AUTO_TEST_CASE (difficultyTestsCustomMainNetwork)
 
 BOOST_AUTO_TEST_CASE (basicDifficultyTest)
 

Variables

std::string const c_testDifficulty
 

Detailed Description

Author
Christoph Jentzsch cj@et.nosp@m.hdev.nosp@m..com
Date
2015 difficulty calculation tests.

Definition in file difficulty.cpp.

Function Documentation

BOOST_AUTO_TEST_CASE ( difficultyTestsFrontier  )

Definition at line 192 of file difficulty.cpp.

Here is the call graph for this function:

BOOST_AUTO_TEST_CASE ( difficultyTestsRopsten  )

Definition at line 206 of file difficulty.cpp.

Here is the call graph for this function:

BOOST_AUTO_TEST_CASE ( difficultyTestsHomestead  )

Definition at line 220 of file difficulty.cpp.

Here is the call graph for this function:

BOOST_AUTO_TEST_CASE ( difficultyTestsMainNetwork  )

Definition at line 234 of file difficulty.cpp.

Here is the call graph for this function:

BOOST_AUTO_TEST_CASE ( difficultyTestsCustomMainNetwork  )

Definition at line 248 of file difficulty.cpp.

Here is the call graph for this function:

BOOST_AUTO_TEST_CASE ( basicDifficultyTest  )

Definition at line 311 of file difficulty.cpp.

Here is the call graph for this function:

void checkCalculatedDifficulty ( BlockHeader const &  _bi,
BlockHeader const &  _parent,
Network  _n,
ChainOperationParams const &  _p,
string const &  _testName = "" 
)

Definition at line 44 of file difficulty.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void fillDifficulty ( string const &  _testFileFullName,
Ethash _sealEngine 
)

Definition at line 104 of file difficulty.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void testDifficulty ( string const &  _testFileFullName,
Ethash _sealEngine,
Network  _n 
)

Definition at line 155 of file difficulty.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Variable Documentation

std::string const c_testDifficulty
Initial value:
= R"(
"DifficultyTest[N]" : {
"parentTimestamp" : "[PSTAMP]",
"parentDifficulty" : "[PDIFF]",
"currentTimestamp" : "[СSTAMP]",
"currentBlockNumber" : "[CNUM]",
"currentDifficulty" : "[CDIFF]"
},
)"

Definition at line 34 of file difficulty.cpp.