orm: add test case for InsertMulti

This commit is contained in:
miraclesu 2016-04-13 20:20:49 +08:00
parent 3a3f70027c
commit 903e21bef2
1 changed files with 6 additions and 0 deletions

View File

@ -2042,6 +2042,12 @@ func TestIntegerPk(t *testing.T) {
throwFail(t, err)
throwFail(t, AssertIs(out.Value, intPk.Value))
}
num, err = dORM.InsertMulti(1, []*IntegerPk{&IntegerPk{
ID: 1, Value: "ok",
}})
throwFail(t, err)
throwFail(t, AssertIs(num, 1))
}
func TestInsertAuto(t *testing.T) {