From 1d5342abc43df02cf0bd69b1e865c0f179182eef Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 29 May 2019 11:03:01 +0200 Subject: Multi step registration --- server/tests/api/check-params/users.ts | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'server/tests') diff --git a/server/tests/api/check-params/users.ts b/server/tests/api/check-params/users.ts index d26032ea5..95097817b 100644 --- a/server/tests/api/check-params/users.ts +++ b/server/tests/api/check-params/users.ts @@ -737,6 +737,13 @@ describe('Test users API validators', function () { await makePostBodyRequest({ url: server.url, path: registrationPath, token: server.accessToken, fields }) }) + it('Should fail with a channel name that is the same than user username', async function () { + const source = { username: 'super_user', channel: { name: 'super_user', displayName: 'display name' } } + const fields = immutableAssign(baseCorrectParams, source) + + await makePostBodyRequest({ url: server.url, path: registrationPath, token: server.accessToken, fields }) + }) + it('Should fail with an existing channel', async function () { const videoChannelAttributesArg = { name: 'existing_channel', displayName: 'hello', description: 'super description' } await addVideoChannel(server.url, server.accessToken, videoChannelAttributesArg) -- cgit v1.2.3