Пример #1
0
        public async Task AddToDoList()
        {
            ToDoListDto addedtoDoList = await _toDoListRepository.Add(new CreateToDoListDto { Description = "buy phone", CreatedBy = 1, UserId = 1, LabelId = 1, IsActive = true });

            Assert.IsNotNull(addedtoDoList);
            Assert.AreEqual("buy phone", addedtoDoList.Description);
        }
Пример #2
0
        public ToDoList ToDoListFilling(User myUser, string listTitle)
        {
            ToDoList toDoList = new ToDoList(myUser.Username, listTitle);

            toDoListRep.Add(toDoList);
            myUser.ToDoListsIds.Add(toDoList.Id);
            return(toDoList);
        }