[MM-31404] api4/config: return error when patching PluginSettings.EnableUploads (#16611)
* api4/config: return error when patching PluginSettings.EnableUploads * reflect review comments Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
81b06b5b72
Коммит
11c6d07d6a
@@ -633,9 +633,13 @@ func TestPatchConfig(t *testing.T) {
|
||||
EnableUploads: model.NewBool(true),
|
||||
}}
|
||||
|
||||
updatedConfig, _ := client.PatchConfig(&config)
|
||||
|
||||
assert.Equal(t, false, *updatedConfig.PluginSettings.EnableUploads)
|
||||
updatedConfig, resp := client.PatchConfig(&config)
|
||||
if client == th.LocalClient {
|
||||
CheckOKStatus(t, resp)
|
||||
assert.Equal(t, true, *updatedConfig.PluginSettings.EnableUploads)
|
||||
} else {
|
||||
CheckForbiddenStatus(t, resp)
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
Ссылка в новой задаче
Block a user