mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-08-23 22:11:36 +08:00
Add unit test
This commit is contained in:
parent
9d9d5b7ee9
commit
332fa189ac
@ -1,4 +1,5 @@
|
||||
using SqlSugar;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
@ -29,9 +30,16 @@ namespace OrmTest
|
||||
db.CodeFirst.InitTables<Charafafa2>();
|
||||
db.Insertable(new Charafafa2() { TimeSpanTimeSpan = TimeSpan.FromSeconds(1) }).ExecuteCommand();
|
||||
var list2=db.Queryable<Charafafa2>().ToList();
|
||||
db.CodeFirst.InitTables<Codeafadfa>();
|
||||
db.Insertable(new Codeafadfa() { Array = JArray.FromObject(new string[] { "a" }) }).ExecuteCommand();
|
||||
Console.WriteLine("#### CodeFirst end ####");
|
||||
}
|
||||
}
|
||||
public class Codeafadfa
|
||||
{
|
||||
[SugarColumn(ColumnDataType ="varchar(500)" )]
|
||||
public object Array { get; set; }
|
||||
}
|
||||
public class Charafafa2
|
||||
{
|
||||
public TimeSpan TimeSpanTimeSpan { get; set; }
|
||||
|
Loading…
Reference in New Issue
Block a user