public async Task AddTask() { var mock = new Mock <IToDoListRepository>(); mock.Setup(m => m.loadTasks()); var tdlService = new ToDoListApp.Service.ToDoListService(mock.Object); Assert.IsNotNull(tdlService.addTask(100, "New task by Mock")); }
public void LoadTasks() { var mock = new Mock <IToDoListRepository>(); mock.Setup(m => m.loadTasks()); var tdlService = new ToDoListApp.Service.ToDoListService(mock.Object); Assert.IsNotNull(mock.Object); }