From f4dcb4edf2aafca85c9af631131a77888da24bc7 Mon Sep 17 00:00:00 2001 From: Martin Kraft Date: Wed, 2 May 2018 07:31:14 -0400 Subject: MM-10182 & MM-10183: Adds channel scheme and team scheme API endpoint. (#8680) * MM-10183: Adds channel scheme API endpoint. MM-10182: Adds team scheme API endpoint. MM-10182_3: Switch from scheme_id in path to body. * MM-10182/MM-10183: Changes path from 'schemes' to 'scheme'. * MM-10182: Fix merge error. --- app/channel_test.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'app/channel_test.go') diff --git a/app/channel_test.go b/app/channel_test.go index de8a6a6a0..336d9b25b 100644 --- a/app/channel_test.go +++ b/app/channel_test.go @@ -381,3 +381,21 @@ func TestAddChannelMemberNoUserRequestor(t *testing.T) { assert.Equal(t, user.Username, post.Props["username"]) } } + +func TestAppUpdateChannelScheme(t *testing.T) { + th := Setup().InitBasic() + defer th.TearDown() + + channel := th.BasicChannel + mockID := model.NewString("x") + channel.SchemeId = mockID + + updatedChannel, err := th.App.UpdateChannelScheme(channel) + if err != nil { + t.Fatal(err) + } + + if updatedChannel.SchemeId != mockID { + t.Fatal("Wrong Channel SchemeId") + } +} -- cgit v1.2.3-1-g7c22