diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2016-08-23 17:42:56 +0200 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2016-08-23 17:42:56 +0200 |
commit | bf68dd752d6e3d5fce791dd8e0df9debb9d96902 (patch) | |
tree | 867e4bef8481b85e81193342922ec60430029838 /server/tests/api | |
parent | de59c48f5f317018e3f746bbe4a7b7efe00109f2 (diff) | |
download | PeerTube-bf68dd752d6e3d5fce791dd8e0df9debb9d96902.tar.gz PeerTube-bf68dd752d6e3d5fce791dd8e0df9debb9d96902.tar.zst PeerTube-bf68dd752d6e3d5fce791dd8e0df9debb9d96902.zip |
Client: fix error display for component
Diffstat (limited to 'server/tests/api')
-rw-r--r-- | server/tests/api/check-params.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/server/tests/api/check-params.js b/server/tests/api/check-params.js index 4f7b26561..e361147bb 100644 --- a/server/tests/api/check-params.js +++ b/server/tests/api/check-params.js | |||
@@ -590,6 +590,17 @@ describe('Test parameters validator', function () { | |||
590 | requestsUtils.makePostBodyRequest(server.url, path, server.accessToken, data, done, 204) | 590 | requestsUtils.makePostBodyRequest(server.url, path, server.accessToken, data, done, 204) |
591 | }) | 591 | }) |
592 | 592 | ||
593 | it('Should fail if we add a user with the same username', function (done) { | ||
594 | it('Should succeed with the correct params', function (done) { | ||
595 | const data = { | ||
596 | username: 'user1', | ||
597 | password: 'my super password' | ||
598 | } | ||
599 | |||
600 | requestsUtils.makePostBodyRequest(server.url, path, server.accessToken, data, done, 409) | ||
601 | }) | ||
602 | }) | ||
603 | |||
593 | it('Should fail with a non admin user', function (done) { | 604 | it('Should fail with a non admin user', function (done) { |
594 | server.user = { | 605 | server.user = { |
595 | username: 'user1', | 606 | username: 'user1', |