public void ShouldGetEdit()
        {
            var author = new Author();
            Expect.Call(authorRepositoryMock.Get(12)).Return(author);

            mocks.ReplayAll();
            var result = controller.Edit(12);
            mocks.VerifyAll();

            Assert.IsType(typeof(AuthorViewModel), result.Model);
        }
 public void CanCorrectlyMapAuthor(Author author)
 {
     new PersistenceSpecification<Author>(UnitOfWorkSession)
         .VerifyTheMappings(author);
 }
        public void ShouldPostDelete()
        {
            var author = new Author();
            Expect.Call(authorRepositoryMock.Get(12)).Return(author);

            mocks.ReplayAll();
            var result = (RedirectToRouteResult)controller.Delete(12);
            mocks.VerifyAll();

            Assert.True(result.RouteValues.ContainsValue("Index"));
        }