18 lines
670 B
C++
18 lines
670 B
C++
|
|
#include <cstdlib>
|
||
|
|
#include <iostream>
|
||
|
|
#include <boost/test/included/unit_test.hpp>
|
||
|
|
|
||
|
|
extern uint32_t GRAPHENE_TESTING_GENESIS_TIMESTAMP;
|
||
|
|
|
||
|
|
boost::unit_test::test_suite* init_unit_test_suite(int argc, char* argv[]) {
|
||
|
|
std::srand(time(NULL));
|
||
|
|
std::cout << "Random number generator seeded to " << time(NULL) << std::endl;
|
||
|
|
const char* genesis_timestamp_str = getenv("GRAPHENE_TESTING_GENESIS_TIMESTAMP");
|
||
|
|
if( genesis_timestamp_str != nullptr )
|
||
|
|
{
|
||
|
|
GRAPHENE_TESTING_GENESIS_TIMESTAMP = std::stoul( genesis_timestamp_str );
|
||
|
|
}
|
||
|
|
std::cout << "GRAPHENE_TESTING_GENESIS_TIMESTAMP is " << GRAPHENE_TESTING_GENESIS_TIMESTAMP << std::endl;
|
||
|
|
return nullptr;
|
||
|
|
}
|