If multiple unit tests exercise code that use random_32_bytes() (or
one of the other randomness functions) to generate randomness, they
could get different values depending on the order in which they run,
as in unit tests, the randomness function use rand().
This commit adds a way for unit tests to reset the PRNG seed so that
unit tests can make sure to get the same values every time,
independent of other tests.
If multiple unit tests exercise code that use random_32_bytes() (or one of the other randomness functions) to generate randomness, they could get different values depending on the order in which they run, as in unit tests, the randomness function use
rand()
.This commit adds a way for unit tests to reset the PRNG seed so that unit tests can make sure to get the same values every time, independent of other tests.