1
0

Ensure case insensitive search on postgres (#927)

Reviewed-on: https://kolaente.dev/vikunja/api/pulls/927
Co-authored-by: konrad <konrad@kola-entertainments.de>
Co-committed-by: konrad <konrad@kola-entertainments.de>
This commit is contained in:
konrad
2021-08-01 21:40:25 +00:00
parent 9c2a59582a
commit 4c5f457313
23 changed files with 308 additions and 108 deletions

View File

@ -103,6 +103,21 @@ func TestLinkSharing_ReadAll(t *testing.T) {
assert.Empty(t, sharing.Password)
}
})
t.Run("search", func(t *testing.T) {
db.LoadAndAssertFixtures(t)
s := db.NewSession()
defer s.Close()
share := &LinkSharing{
ListID: 1,
}
all, _, _, err := share.ReadAll(s, doer, "wITHPASS", 1, -1)
shares := all.([]*LinkSharing)
assert.NoError(t, err)
assert.Len(t, shares, 1)
assert.Equal(t, int64(4), shares[0].ID)
})
}
func TestLinkSharing_ReadOne(t *testing.T) {