public void CheckCreatorAndReader() { using (var context = PrepareContext()) { CleanDatabase(context); var storageSaver = new DbStorage(context); var creator = new ListItemCreator(storageSaver); creator.Add("a list item"); var item = context.ToDoListItems.Single(); Assert.False(item.IsDone); Assert.Equal("a list item", item.Name); } }
private void Act(string listItemName) { listItemCreator.Add(listItemName); }