summaryrefslogtreecommitdiffstats
path: root/plugin/plugintest
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2018-08-29 14:07:27 -0400
committerChristopher Speller <crspeller@gmail.com>2018-08-29 11:07:27 -0700
commit9c76d9ba0031ee4175db6960024d61c23cc98659 (patch)
tree798c48c4064fcafe2401516436967af208288b1d /plugin/plugintest
parent0da5c852f05faf6c08026b9a16f8362564b27915 (diff)
downloadchat-9c76d9ba0031ee4175db6960024d61c23cc98659.tar.gz
chat-9c76d9ba0031ee4175db6960024d61c23cc98659.tar.bz2
chat-9c76d9ba0031ee4175db6960024d61c23cc98659.zip
Add GetLDAPUserAttributes method to the plugin API (#9326)
Diffstat (limited to 'plugin/plugintest')
-rw-r--r--plugin/plugintest/api.go25
1 files changed, 25 insertions, 0 deletions
diff --git a/plugin/plugintest/api.go b/plugin/plugintest/api.go
index e84ceffd8..32fab3595 100644
--- a/plugin/plugintest/api.go
+++ b/plugin/plugintest/api.go
@@ -524,6 +524,31 @@ func (_m *API) GetGroupChannel(userIds []string) (*model.Channel, *model.AppErro
return r0, r1
}
+// GetLDAPUserAttributes provides a mock function with given fields: userId, attributes
+func (_m *API) GetLDAPUserAttributes(userId string, attributes []string) (map[string]string, *model.AppError) {
+ ret := _m.Called(userId, attributes)
+
+ var r0 map[string]string
+ if rf, ok := ret.Get(0).(func(string, []string) map[string]string); ok {
+ r0 = rf(userId, attributes)
+ } else {
+ if ret.Get(0) != nil {
+ r0 = ret.Get(0).(map[string]string)
+ }
+ }
+
+ var r1 *model.AppError
+ if rf, ok := ret.Get(1).(func(string, []string) *model.AppError); ok {
+ r1 = rf(userId, attributes)
+ } else {
+ if ret.Get(1) != nil {
+ r1 = ret.Get(1).(*model.AppError)
+ }
+ }
+
+ return r0, r1
+}
+
// GetPost provides a mock function with given fields: postId
func (_m *API) GetPost(postId string) (*model.Post, *model.AppError) {
ret := _m.Called(postId)