Exemple #1
0
        public void CalculateSnowBehindParapetTest()
        {
            // Arrange
            SnowLoadsController controller = new SnowLoadsController();
            var buildingData = CreateBuildingData(DesignSituation.B3, true);
            var model        = CreateExceptionalSnowBehindParapet(buildingData);

            // Act
            ViewResult result = controller.CalculateExceptionalSnowBehindParapet(model, buildingData) as ViewResult;

            // Assert
            Assert.IsNotNull(result);
            Assert.AreEqual("ExceptionalSnowBehindParapetResult", result.ViewName);
            Assert.IsTrue(result.Model.GetType() == typeof(ExceptionalSnowLoadSnowBehindParapet));
            Assert.AreNotEqual(0, model.ExceptionalSnowBehindParapet.SnowLoad);
        }