diff options
author | Christopher Speller <crspeller@gmail.com> | 2016-09-22 08:31:38 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-22 08:31:38 -0400 |
commit | efdb0dfa0b422b24a6fbed2c4752484494a78857 (patch) | |
tree | de94d8ae0f9e6c9bc91e504d93dc7f55219da52f /webapp/tests | |
parent | de79343b9aa9dc601e5633cef329e1a83452aa1a (diff) | |
download | chat-efdb0dfa0b422b24a6fbed2c4752484494a78857.tar.gz chat-efdb0dfa0b422b24a6fbed2c4752484494a78857.tar.bz2 chat-efdb0dfa0b422b24a6fbed2c4752484494a78857.zip |
Fixing update roles API (#4060)
Diffstat (limited to 'webapp/tests')
-rw-r--r-- | webapp/tests/client_team.test.jsx | 19 | ||||
-rw-r--r-- | webapp/tests/client_user.test.jsx | 15 |
2 files changed, 25 insertions, 9 deletions
diff --git a/webapp/tests/client_team.test.jsx b/webapp/tests/client_team.test.jsx index 389a6ef50..157a2f4a5 100644 --- a/webapp/tests/client_team.test.jsx +++ b/webapp/tests/client_team.test.jsx @@ -240,5 +240,24 @@ describe('Client.Team', function() { ); }); }); + + it('updateTeamMemberRoles', function(done) { + TestHelper.initBasic(() => { + var user = TestHelper.basicUser(); + var team = TestHelper.basicTeam(); + + TestHelper.basicClient().updateTeamMemberRoles( + team.id, + user.id, + '', + function() { + done(); + }, + function(err) { + done(new Error(err.message)); + } + ); + }); + }); }); diff --git a/webapp/tests/client_user.test.jsx b/webapp/tests/client_user.test.jsx index 6c65e8ef5..48a0150d4 100644 --- a/webapp/tests/client_user.test.jsx +++ b/webapp/tests/client_user.test.jsx @@ -211,21 +211,18 @@ describe('Client.User', function() { }); }); - it('updateRoles', function(done) { + it('updateUserRoles', function(done) { TestHelper.initBasic(() => { var user = TestHelper.basicUser(); - var team = TestHelper.basicTeam(); - TestHelper.basicClient().updateRoles( - team.id, + TestHelper.basicClient().updateUserRoles( user.id, '', - function(data) { - assert.equal(data.user_id, user.id); - done(); + function() { + done(new Error('Not supposed to work')); }, - function(err) { - done(new Error(err.message)); + function() { + done(); } ); }); |