From 2502913410212490f7b9a6dc5eea74267b36606a Mon Sep 17 00:00:00 2001 From: sunkaixuan <610262374@qq.com> Date: Sat, 24 Jun 2023 22:43:18 +0800 Subject: [PATCH] Add unit test --- .../SqlServerTest/UnitTest/UnitManyToMany3.cs | 30 +++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/Src/Asp.Net/SqlServerTest/UnitTest/UnitManyToMany3.cs b/Src/Asp.Net/SqlServerTest/UnitTest/UnitManyToMany3.cs index 9c84e7f16..d1385aa37 100644 --- a/Src/Asp.Net/SqlServerTest/UnitTest/UnitManyToMany3.cs +++ b/Src/Asp.Net/SqlServerTest/UnitTest/UnitManyToMany3.cs @@ -105,8 +105,34 @@ namespace OrmTest { throw new Exception("unit error"); } - - } + + db.UpdateNav(new OperatorInfo() + { + id = "1113", + createTime = DateTime.Now, + isDel = 1, + isDisabled = 1, + openid = "", + phone = "", + pwd = "", + realname = "a01", + remark = "a", + sno = "a", + username = "admin", + Roles = new List() { new Role() { id = 2 } } + }).Include(z => z.Roles, + new UpdateNavOptions() + { + ManyToManySaveMappingTemplate = new OptRole() + { + CreateTime = "1010", + OrgId = "1x" + + } + }) + .ExecuteCommand(); + + } /// /// 描述: