From 715097cc76510a3d78ba83e8544ee7c956ed26e9 Mon Sep 17 00:00:00 2001 From: Jesse Hallam Date: Wed, 17 Oct 2018 11:24:12 -0400 Subject: MM-12234: configurable limit to user autocomplete and search matches (#9499) * unit test cleanup * allow limiting user search results * clean up test users before starting * model UserSearchOptions to simplify parameters --- store/storetest/mocks/ChannelStore.go | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to 'store/storetest/mocks/ChannelStore.go') diff --git a/store/storetest/mocks/ChannelStore.go b/store/storetest/mocks/ChannelStore.go index 9d42d0b65..7ad8f100d 100644 --- a/store/storetest/mocks/ChannelStore.go +++ b/store/storetest/mocks/ChannelStore.go @@ -314,6 +314,22 @@ func (_m *ChannelStore) GetChannelMembersForExport(userId string, teamId string) return r0 } +// GetChannelMembersTimezones provides a mock function with given fields: channelId +func (_m *ChannelStore) GetChannelMembersTimezones(channelId string) store.StoreChannel { + ret := _m.Called(channelId) + + var r0 store.StoreChannel + if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok { + r0 = rf(channelId) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(store.StoreChannel) + } + } + + return r0 +} + // GetChannelUnread provides a mock function with given fields: channelId, userId func (_m *ChannelStore) GetChannelUnread(channelId string, userId string) store.StoreChannel { ret := _m.Called(channelId, userId) @@ -442,21 +458,6 @@ func (_m *ChannelStore) GetMember(channelId string, userId string) store.StoreCh return r0 } -func (_m *ChannelStore) GetChannelMembersTimezones(channelId string) store.StoreChannel { - ret := _m.Called(channelId) - - var r0 store.StoreChannel - if rf, ok := ret.Get(0).(func(string) store.StoreChannel); ok { - r0 = rf(channelId) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).(store.StoreChannel) - } - } - - return r0 -} - // GetMemberCount provides a mock function with given fields: channelId, allowFromCache func (_m *ChannelStore) GetMemberCount(channelId string, allowFromCache bool) store.StoreChannel { ret := _m.Called(channelId, allowFromCache) -- cgit v1.2.3-1-g7c22