public void SetUp() { _auditoryRepository = Mock.Of <IAuditoryRepository>(); _auditoryService = new AuditoryService(_auditoryRepository); _auditory = new AuditoryItem() { Id = 1, Number = 1, FullName = "Auditory 1", Memo = "New auditory 1", Level = 1, Capacity = 1 }; }
/// <summary> /// Конструктор класс. /// </summary> /// <param name="auditory_repository">Интерфейс репозитория аудиторий.</param> public AuditoryService(IAuditoryRepository auditory_repository) { _auditoryRepository = auditory_repository; }
/// <summary> /// Конструктор без параметров. /// </summary> public AuditoryService() { _auditoryRepository = new AuditoryRepository(); }
public void SetUp() { _auditoryRepository = Mock.Of<IAuditoryRepository>(); _auditoryService = new AuditoryService(_auditoryRepository); _auditory = new AuditoryItem() { Id = 1, Number = 1, FullName = "Auditory 1", Memo = "New auditory 1", Level = 1, Capacity = 1 }; }