This commit is contained in:
Lunny Xiao 2018-04-09 16:04:15 +08:00
parent ef3e7c1c89
commit 927317b91d
No known key found for this signature in database
GPG Key ID: C3B7C91B632F738A
1 changed files with 1 additions and 1 deletions

View File

@ -248,7 +248,7 @@ func TestDistinct(t *testing.T) {
users2 := make([]Depart, 0)
err = testEngine.Distinct(departname).Table(new(Userinfo)).Find(&users2)
assert.NoError(t, err)
if len(users2) != 2 {
if len(users2) != 1 {
fmt.Println(len(users2))
t.Error(err)
panic(errors.New("should be one record"))