-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
@testset
: with Xoshiro, restore Random.GLOBAL_SEED (#43188)
A `@testset` is supposed to restore the "global RNG state" as it was before execution (so that they can be re-ordered easily, etc.) Also, before a testset starts, the default RNG is re-seeded with the "global seed" (to help reproduce test failures). Before `Xoshiro` as the default RNG, the "global seed" was stored within a `MersenneTwister` object. It was enough for a testset to copy the default RNG at the start, and copy it back at the end. But now the global seed is stored outside of the RNG, so it should also be restored separately.
- Loading branch information
Showing
3 changed files
with
28 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters