public void Update() { var manager = new AuthorManager(new UnitOfWork("development")); manager.DeleteAll(); manager.Add(new BusinessLayer.Models.Author("test-first", "test-Last")); var authors = manager.GetAll(); Assert.AreEqual(authors.Count, 1); var author = manager.Get(authors[0].ID); Assert.AreEqual(author.Firstname, "test-first"); Assert.AreEqual(author.Surname, "test-Last"); author.SetSurname("test-Sur"); author.SetFirstName("test-First"); manager.Update(author); authors = manager.GetAll(); Assert.AreEqual(authors.Count, 1); author = manager.Get(authors[0].ID); Assert.AreEqual(author.Firstname, "test-First"); Assert.AreEqual(author.Surname, "test-Sur"); manager.DeleteAll(); }