Update unit test

This commit is contained in:
sunkaixuan 2022-12-18 18:37:43 +08:00
parent 9a00bc99d4
commit 7f2a18bcd8

View File

@ -14,17 +14,17 @@ namespace OrmTest
public static void Init() public static void Init()
{ {
var db = NewUnitTest.Db; var db = NewUnitTest.Db;
db.Insertable(new Order() { Name = "a" }).ExecuteCommand(); db.Insertable(new Order1() { Name = "a" }).ExecuteCommand();
db.Insertable(new List<Order>() { db.Insertable(new List<Order1>() {
new Order() { Name = "a" }, new Order1() { Name = "a" },
new Order() { Name = "a" } new Order1() { Name = "a" }
}).ExecuteCommand(); }).ExecuteCommand();
db.Insertable(new ORDER() { Name = "a" }).ExecuteCommand(); db.Insertable(new ORDER1() { Name = "a" }).ExecuteCommand();
} }
public class Order public class Order1
{ {
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)] [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
public int Id { get; set; } public int Id { get; set; }
@ -39,7 +39,7 @@ namespace OrmTest
public int CustomId { get; set; } public int CustomId { get; set; }
} }
public class ORDER public class ORDER1
{ {
[SugarColumn(IsPrimaryKey = true, IsIdentity = true)] [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
public int Id { get; set; } public int Id { get; set; }