Esempio n. 1
0
            public void Should_get_null_given_null_length_and_Items_length()
            {
                HbmProperty property = new HbmProperty
                {
                    Items = new object[] { new HbmColumn() }
                };
                int?result = property.GetMaxLength();

                result.ShouldBeNull();
            }
Esempio n. 2
0
            public void Should_get_the_correct_value_from_length_if_not_null()
            {
                const int   expected = 16;
                HbmProperty property = new HbmProperty
                {
                    length = expected.ToString()
                };
                int?result = property.GetMaxLength();

                result.ShouldNotBeNull();
                result.Value.ShouldBeEqualTo(expected);
            }
Esempio n. 3
0
            public void Should_get_the_correct_value_from_Items_given_null_length()
            {
                const int   expected = 16;
                HbmProperty property = new HbmProperty
                {
                    Items = new object[]
                    {
                        new HbmColumn
                        {
                            length = expected.ToString()
                        }
                    }
                };
                int?result = property.GetMaxLength();

                result.ShouldNotBeNull();
                result.Value.ShouldBeEqualTo(expected);
            }