public void IndexActionShouldReturnSomePosts()
        {
            var sut = new HomeController();
            var action = sut.Index() as ViewResult;

            Assert.That(action.ViewData.Model, Is.InstanceOf(typeof(IList<Post>)));
        }
 public void IndexACtionModelShouldNotBeEmpty()
 {
     var sut = new HomeController();
     var action = sut.Index() as ViewResult;
     var posts = action.ViewData.Model as IList<Post>;
     Assert.That(posts, Is.Not.Empty);
 }
 public void PostShouldHaveABodyOfBoo()
 {
     var sut = new HomeController();
     var action = sut.Index() as ViewResult;
     var posts = action.ViewData.Model as IList<Post>;
     var actual = posts[0];
     Assert.That(actual.Body, Is.EqualTo("Boo"));
 }
 public void IndexACtionSHouldDIsplayPosts()
 {
     var controller = new HomeController();
     var actual = controller.Index() as ViewResult;
     Assert.That(actual.ViewName, Is.EqualTo("Index"));
 }