public void CollectionGeneratorTests(int noteCount, int cardCount, int maxCardPerNote) { IEnumerable <Note> notes = new CollectionGenerator( new CardGenerator(new TimeGenerator(), CollectionConfig.Default, cardCount), noteCount, maxCardPerNote).Generate(); notes.Count().Should().Be(noteCount); notes.Sum(n => n.Cards.Count).Should().Be(cardCount); notes.Max(n => n.Cards.Count).Should().BeLessOrEqualTo(maxCardPerNote); notes.Min(n => n.Cards.Count).Should().BeGreaterOrEqualTo(1); notes.Average(n => n.Cards.Count).Should().Be((double)cardCount / (double)noteCount); }