From 0267a1f76e48ae833a4f951c82e69db59d39b314 Mon Sep 17 00:00:00 2001 From: Hanzei <16541325+hanzei@users.noreply.github.com> Date: Mon, 15 Oct 2018 15:19:36 +0200 Subject: Add GetPostThread() to plugin API (#9652) --- plugin/plugintest/api.go | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'plugin/plugintest') diff --git a/plugin/plugintest/api.go b/plugin/plugintest/api.go index c11446bda..c0302c1cf 100644 --- a/plugin/plugintest/api.go +++ b/plugin/plugintest/api.go @@ -599,6 +599,31 @@ func (_m *API) GetPost(postId string) (*model.Post, *model.AppError) { return r0, r1 } +// GetPostThread provides a mock function with given fields: postId +func (_m *API) GetPostThread(postId string) (*model.PostList, *model.AppError) { + ret := _m.Called(postId) + + var r0 *model.PostList + if rf, ok := ret.Get(0).(func(string) *model.PostList); ok { + r0 = rf(postId) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*model.PostList) + } + } + + var r1 *model.AppError + if rf, ok := ret.Get(1).(func(string) *model.AppError); ok { + r1 = rf(postId) + } else { + if ret.Get(1) != nil { + r1 = ret.Get(1).(*model.AppError) + } + } + + return r0, r1 +} + // GetPostsForChannel provides a mock function with given fields: channelId, page, perPage func (_m *API) GetPostsForChannel(channelId string, page int, perPage int) (*model.PostList, *model.AppError) { ret := _m.Called(channelId, page, perPage) -- cgit v1.2.3-1-g7c22