Beispiel #1
0
        public void Index()
        {
            // Arrange
            StartController controller = new StartController();

            // Act
            ViewResult result = controller.Index() as ViewResult;

            // Assert
            Assert.IsNotNull(result);
        }
Beispiel #2
0
        public void Index()
        {
            // Setup
            _homeController.CurrentItem = new StartPage();

            // Execute
            var result = _homeController.Index() as ViewResult;

            // Verify
            var item = result.ViewData.Model as StartPage;

            Assert.That(item, Is.EqualTo(_homeController.CurrentItem));
        }