我正在将我的项目从 NUnit 2.6.3 迁移到 3.2.1。我发现“Randomizer”类从“NUnit.Framework”移动到“NUnit.Framework.Internal”,但我找不到方法 Randomizer.GetDoubles 或任何等效方法。
有什么想法吗?
最佳答案
Randomizer 类已被移动,现在可以通过 TestContext.CurrentContext.Random
访问。
不再有 Randomizer.GetDoubles
,但有 Randomizer.NextDouble(double min, double max)
方法。
[ Docs ]
关于c# - Nunit 3 中的随机发生器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37864275/