Bitcoin Core 28.99.0
P2P Digital Currency
Functions
random_tests.cpp File Reference
#include <random.h>
#include <test/util/random.h>
#include <test/util/setup_common.h>
#include <util/time.h>
#include <boost/test/unit_test.hpp>
#include <algorithm>
#include <random>
Include dependency graph for random_tests.cpp:

Go to the source code of this file.

Functions

 BOOST_AUTO_TEST_CASE (osrandom_tests)
 
 BOOST_AUTO_TEST_CASE (fastrandom_tests_deterministic)
 
 BOOST_AUTO_TEST_CASE (fastrandom_tests_nondeterministic)
 
 BOOST_AUTO_TEST_CASE (fastrandom_randbits)
 
 BOOST_AUTO_TEST_CASE (randbits_test)
 Verify that RandomMixin::randbits returns 0 and 1 for every requested bit. More...
 
 BOOST_AUTO_TEST_CASE (stdrandom_test)
 Does-it-compile test for compatibility with standard library RNG interface. More...
 
 BOOST_AUTO_TEST_CASE (shuffle_stat_test)
 Test that Shuffle reaches every permutation with equal probability. More...
 
 BOOST_AUTO_TEST_CASE (xoroshiro128plusplus_reference_values)
 

Function Documentation

◆ BOOST_AUTO_TEST_CASE() [1/8]

BOOST_AUTO_TEST_CASE ( fastrandom_randbits  )

Definition at line 115 of file random_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [2/8]

BOOST_AUTO_TEST_CASE ( fastrandom_tests_deterministic  )

Definition at line 23 of file random_tests.cpp.

◆ BOOST_AUTO_TEST_CASE() [3/8]

BOOST_AUTO_TEST_CASE ( fastrandom_tests_nondeterministic  )

Definition at line 81 of file random_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [4/8]

BOOST_AUTO_TEST_CASE ( osrandom_tests  )

Definition at line 18 of file random_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [5/8]

BOOST_AUTO_TEST_CASE ( randbits_test  )

Verify that RandomMixin::randbits returns 0 and 1 for every requested bit.

< RNG for producing the lengths requested from ctx_test.

< The RNGs being tested.

< (Assumed value of) ctx_test::bitbuf_len

Definition at line 131 of file random_tests.cpp.

Here is the call graph for this function:

◆ BOOST_AUTO_TEST_CASE() [6/8]

BOOST_AUTO_TEST_CASE ( shuffle_stat_test  )

Test that Shuffle reaches every permutation with equal probability.

Definition at line 213 of file random_tests.cpp.

◆ BOOST_AUTO_TEST_CASE() [7/8]

BOOST_AUTO_TEST_CASE ( stdrandom_test  )

Does-it-compile test for compatibility with standard library RNG interface.

Definition at line 195 of file random_tests.cpp.

◆ BOOST_AUTO_TEST_CASE() [8/8]

BOOST_AUTO_TEST_CASE ( xoroshiro128plusplus_reference_values  )

Definition at line 242 of file random_tests.cpp.

Here is the call graph for this function: