add UpdateUserRoles to plugin api (#26615)

* ProfileImageBytes for EnsureBotOptions

* leverage plugintest.NewAPI

* fix linting

* add UpdateUserRoles to plugin api
Этот коммит содержится в:
Jesse Hallam
2024-03-29 19:22:54 -03:00
коммит произвёл GitHub
родитель f34fac7731
Коммит acbaf4c283
7 изменённых файлов: 137 добавлений и 0 удалений

Просмотреть файл

@@ -4355,6 +4355,34 @@ func (_m *API) UpdateUserCustomStatus(userID string, customStatus *model.CustomS
return r0
}
// UpdateUserRoles provides a mock function with given fields: userID, newRoles
func (_m *API) UpdateUserRoles(userID string, newRoles string) (*model.User, *model.AppError) {
ret := _m.Called(userID, newRoles)
var r0 *model.User
var r1 *model.AppError
if rf, ok := ret.Get(0).(func(string, string) (*model.User, *model.AppError)); ok {
return rf(userID, newRoles)
}
if rf, ok := ret.Get(0).(func(string, string) *model.User); ok {
r0 = rf(userID, newRoles)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(*model.User)
}
}
if rf, ok := ret.Get(1).(func(string, string) *model.AppError); ok {
r1 = rf(userID, newRoles)
} else {
if ret.Get(1) != nil {
r1 = ret.Get(1).(*model.AppError)
}
}
return r0, r1
}
// UpdateUserStatus provides a mock function with given fields: userID, status
func (_m *API) UpdateUserStatus(userID string, status string) (*model.Status, *model.AppError) {
ret := _m.Called(userID, status)