コード例 #1
0
        public void Index_RendersView()
        {
            var controller = new GuestbookController(new FakeGuestbookRepository());

            var result = controller.Index() as ViewResult;

            Assert.IsNotNull(result);
        }
コード例 #2
0
        public void Index_gets_most_recent_entries()
        {
            var controller = new GuestbookController(new FakeGuestbookRepository());

            var result = (ViewResult)controller.Index();

            var guestbookEntries = (IList<GuestbookEntry>)result.Model;
        }