Beispiel #1
0
        public void Random3()
        {
            var random = FRandom.SeedDefault();

            Assert.AreEqual(2, FRandom.Next(random, 0, 5).Number);
            Assert.AreEqual(2, FRandom.Next(random, 0, 5).Number);
            Assert.AreEqual(2, FRandom.Next(random, 0, 5).Number);
        }
Beispiel #2
0
        public void RandomSkip()
        {
            var random = FRandom.SeedDefault();
            var sb     = new StringBuilder();

            for (int i = 0; i < 10; i++)
            {
                var result = FRandom.Skip(i, random, 0, 10);
                sb.Append(result.Number).Append(" ");
            }
            string gen1Results = sb.ToString();

            Assert.AreEqual("5 1 2 2 8 0 2 7 9 0 ", gen1Results);
        }