Esempio n. 1
0
            private void ItShouldWriteItToDisk()
            {
                var writer = new FakeWriter();

                LotteryNumberSetWriter.WriteSet(writer,
                                                LotteryNumberSet.Generate(() => LotteryNumber.Generate(new MonoStateRandomNumberGenerator(Int32.MaxValue))));

                Assert.True(writer.Written);
            }
Esempio n. 2
0
            private void TheSetShouldHaveSixNumbers()
            {
                var set = LotteryNumberSet.Generate(() => LotteryNumber.Generate(new MonoStateRandomNumberGenerator(Int32.MaxValue)));

                Assert.Equal(6, set.Count);
            }
Esempio n. 3
0
            private void DuplicateNumbersShouldNeverBeAllowed()
            {
                var set = LotteryNumberSet.Generate(() => LotteryNumber.Generate(new FakeRandomNumberGenerator()));

                Assert.Equal(6, set.Count);
            }