public void ValidatePowerTradeCollection_DifferentDates_Expect_Exception() { // Arrange var tradesCount = TestHelper.GenerateIntFrom1To99(); var periodsCount = TestHelper.GenerateIntFrom1To99(); var date = new Fixture().Create <DateTime>(); var powerTrades = TestHelper.BuildPowerTradesCollection(tradesCount, periodsCount, date); powerTrades.FirstOrDefault().Date = date.AddDays(-10); // Assert Assert.Throws(typeof(ArgumentException), () => _manager.Validate(powerTrades)); }