示例#1
0
        public void Concat()
        {
            _test1 = new SqlString("First TestString");
            _test2 = new SqlString("This is just a test SqlString");
            _test3 = new SqlString("This is just a test SqlString");

            Assert.Equal("First TestStringThis is just a test SqlString", SqlString.Concat(_test1, _test2));
            Assert.Equal(SqlString.Null, SqlString.Concat(_test1, SqlString.Null));
        }
示例#2
0
        public void String_Concat()
        {
            const string s1 = "First string comes before the ";
            const string s2 = "Second string that comes after";
            var sqlString1 = new SqlString(s1);
            var sqlString2 = new SqlString(s2);

            var sqlString3 = new SqlString();
            Assert.DoesNotThrow(() => sqlString3 = sqlString1.Concat(sqlString2));
            Assert.AreEqual("First string comes before the Second string that comes after", sqlString3.Value);
        }
示例#3
0
        public void Concat()
        {
            Test1 = new SqlString("First TestString");
            Test2 = new SqlString("This is just a test SqlString");
            Test3 = new SqlString("This is just a test SqlString");

            Assert.AreEqual((SqlString)"First TestStringThis is just a test SqlString",
                            SqlString.Concat(Test1, Test2), "#K01");

            Assert.AreEqual(SqlString.Null,
                            SqlString.Concat(Test1, SqlString.Null), "#K02");
        }