[MM-21793] Allow bots to be added to group synced channels and teams (#13672)
* MM-21793: Allow bots to be removed and added from group synced teams and channels * MM-21793: Add tests for adding and removing a team and channel members * MM-21793 Add punctuation to comments and remove unnecessary variable
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
ffb3897c8c
Коммит
fa769e46d7
@@ -194,6 +194,28 @@ func (me *TestHelper) CreateUserOrGuest(guest bool) *model.User {
|
||||
return user
|
||||
}
|
||||
|
||||
func (me *TestHelper) CreateBot() *model.Bot {
|
||||
id := model.NewId()
|
||||
|
||||
bot := &model.Bot{
|
||||
Username: "bot" + id,
|
||||
DisplayName: "a bot",
|
||||
Description: "bot",
|
||||
OwnerId: me.BasicUser.Id,
|
||||
}
|
||||
|
||||
me.App.Log.SetConsoleLevel(mlog.LevelError)
|
||||
bot, err := me.App.CreateBot(bot)
|
||||
if err != nil {
|
||||
mlog.Error(err.Error())
|
||||
|
||||
time.Sleep(time.Second)
|
||||
panic(err)
|
||||
}
|
||||
me.App.Log.SetConsoleLevel(mlog.LevelDebug)
|
||||
return bot
|
||||
}
|
||||
|
||||
func (me *TestHelper) CreateChannel(team *model.Team) *model.Channel {
|
||||
return me.createChannel(team, model.CHANNEL_OPEN)
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user