Пример #1
0
        public void GetByYearReturnsSomeResults()
        {
            var tr = _sf.InsertRequirement();
            var expectedTraining = _sf.InsertTraining(tr.Id, new DateTime(2018, 3, 1));
            var staffTrainings   = _repo.GetStaffTrainingByYearMonth(2017, 7).ToArray();

            staffTrainings.ShouldHaveSingleItem();
            staffTrainings.ShouldContain(training => training.Id == expectedTraining.Id);
        }
Пример #2
0
 public IList <StaffTraining> GetByYear(int year)
 {
     return(_trainingRepository.GetStaffTrainingByYearMonth(year, DateTime.Now.Month).ToList());
 }