public void TestCreateTodoItemCount() { int initialTodoCount = todoItems.Count(); todoItemService.CreateTodoItem(firstUser, firstDescription); int todoCountAfterCreate = todoItems.Count(); Assert.That(initialTodoCount + 1, Is.EqualTo(todoCountAfterCreate)); }
public IActionResult CreateTodoItem([FromBody] TodoItem todoItem) { return(_todoItemService.CreateTodoItem(todoItem)); }