3383c24be0
This commit removes and now forbids all uses of Collections#shuffle(List) and Random#<init>() across the codebase. The rationale for removing and forbidding these methods is to increase test reproducibility. As these methods use non-reproducible seeds, production code and tests that rely on these methods contribute to non-reproducbility of tests. Instead of Collections#shuffle(List) the method Collections#shuffle(List, Random) can be used. All that is required then is a reproducible source of randomness. Consequently, the utility class Randomness has been added to assist in creating reproducible sources of randomness. Instead of Random#<init>(), Random#<init>(long) with a reproducible seed or the aforementioned Randomess class can be used. Closes #15287 |
||
---|---|---|
.. | ||
lang-expression | ||
lang-groovy | ||
lang-mustache | ||
build.gradle |