public void GetAttributeBody_returns_body()
        {
            var configuration = new MaxLengthConfiguration { MaxLength = 30 };
            var code = new CSharpCodeHelper();

            Assert.Equal("MaxLength(30)", configuration.GetAttributeBody(code));
        }
        public void GetMethodChain_returns_chain()
        {
            var configuration = new MaxLengthConfiguration { MaxLength = 30 };
            var code = new CSharpCodeHelper();

            Assert.Equal(".HasMaxLength(30)", configuration.GetMethodChain(code));
        }
Esempio n. 3
0
        public void GetAttributeBody_returns_body()
        {
            var configuration = new MaxLengthConfiguration {
                MaxLength = 30
            };
            var code = new CSharpCodeHelper();

            Assert.Equal("MaxLength(30)", configuration.GetAttributeBody(code));
        }
Esempio n. 4
0
        public void GetMethodChain_returns_chain()
        {
            var configuration = new MaxLengthConfiguration {
                MaxLength = 30
            };
            var code = new CSharpCodeHelper();

            Assert.Equal(".HasMaxLength(30)", configuration.GetMethodChain(code));
        }