Add unit test

This commit is contained in:
sunkaixuan
2023-01-11 20:43:08 +08:00
parent 4daf4497e0
commit 565aa8a7b9
3 changed files with 132 additions and 0 deletions

View File

@@ -37,6 +37,9 @@ namespace OrmTest
{
throw new Exception("unit error");
}
db.Aop.OnLogExecuting = (s1, p1) => Console.WriteLine(s1);
var x2 = db.QueryableWithAttr<OptRole>()
.Where(it => it.Roleinfo.id == 101).ToList();
}
/// <summary>
/// 描述:
@@ -113,6 +116,9 @@ namespace OrmTest
/// </summary>
public int roleId { get; set; }
[Navigate(NavigateType.OneToOne,nameof(roleId))]
public Role Roleinfo { get; set; }
}
}