- 修复 MySql 字符串反斜杠无效的 bug;

This commit is contained in:
28810
2020-04-12 19:00:29 +08:00
parent bd79fc803e
commit 613940df20
15 changed files with 87 additions and 22 deletions

View File

@ -275,7 +275,7 @@ namespace FreeSql.Tests.MySqlConnector
testFieldSByteNullable = 99,
testFieldShort = short.MaxValue,
testFieldShortNullable = short.MinValue,
testFieldString = "<22><><EFBFBD><EFBFBD><EFBFBD>й<EFBFBD><D0B9><EFBFBD>string",
testFieldString = "<22><><EFBFBD><EFBFBD><EFBFBD>й<EFBFBD><D0B9><EFBFBD>string'\\?!@#$%^&*()_+{}}{~?><<>",
testFieldTimeSpan = TimeSpan.FromSeconds(999),
testFieldTimeSpanNullable = TimeSpan.FromSeconds(60),
testFieldUInt = uint.MaxValue,
@ -288,6 +288,11 @@ namespace FreeSql.Tests.MySqlConnector
};
item2.Id = (int)insert.AppendData(item2).ExecuteIdentity();
var newitem2 = select.Where(a => a.Id == item2.Id).ToOne();
Assert.Equal(item2.testFieldString, newitem2.testFieldString);
item2.Id = (int)insert.NoneParameter().AppendData(item2).ExecuteIdentity();
newitem2 = select.Where(a => a.Id == item2.Id).ToOne();
Assert.Equal(item2.testFieldString, newitem2.testFieldString);
var items = select.ToList();
}