Example #1
0
        public void Create_And_Fill_Properties()
        {
            //Arrange
            var attribute = new Attribute
            {
                TypId       = int.MinValue,
                SubTypeId   = int.MaxValue,
                Description = string.Empty,
                Text        = string.Empty,
                Ban         = true
            };

            //Act
            var typId       = attribute.TypId;
            var subTypeId   = attribute.SubTypeId;
            var description = attribute.Description;
            var text        = attribute.Text;
            var ban         = attribute.Ban;

            //Assert
            Assert.Multiple(() =>
            {
                Assert.IsTrue(typId == int.MinValue);
                Assert.IsTrue(int.MaxValue == subTypeId);
                Assert.IsTrue(description == string.Empty);
                Assert.IsTrue(text == string.Empty);
                Assert.IsTrue(ban);
            });
        }
Example #2
0
        public static string GetAmenityOfRoomClassContent(this IHtmlHelper helper, Attribute attribute)
        {
            if (!AttributesToClasses.TryGetValue(attribute.Id, out var cssClass))
            {
                cssClass = "fas fa-check-circle";
            }

            return cssClass;
        }
Example #3
0
        public static string GetClassContent(this IHtmlHelper helper, Attribute attribute)
        {
            if (!AttributesToClasses.TryGetValue(attribute.Id, out var cssClass))
            {
                cssClass = "far fa-dot-circle";
            }

            return cssClass;
        }
Example #4
0
        public static string GetPaymentClassContent(this IHtmlHelper helper, Attribute attribute)
        {
            if (!AttributesToClasses.TryGetValue(attribute.Id, out var cssClass))
            {
                cssClass = "fab fa-credit-card";
            }

            return cssClass;
        }
Example #5
0
        public void Instance_Implement_Interface_IHaveId()
        {
            //Arrange
            var type = typeof(IHaveId <int>);

            //Act
            var attribute = new Attribute();

            //Assert
            Assert.IsInstanceOf(type, attribute);
        }