diff options
Diffstat (limited to 'server/tests')
-rw-r--r-- | server/tests/api/videos/video-channels.ts | 5 | ||||
-rw-r--r-- | server/tests/fixtures/peertube-plugin-test-id-pass-auth-three/main.js | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/server/tests/api/videos/video-channels.ts b/server/tests/api/videos/video-channels.ts index bbb9b12d6..ffe6eef73 100644 --- a/server/tests/api/videos/video-channels.ts +++ b/server/tests/api/videos/video-channels.ts | |||
@@ -430,7 +430,7 @@ describe('Test video channels', function () { | |||
430 | expect(body.data[1].displayName).to.equal('video channel updated') | 430 | expect(body.data[1].displayName).to.equal('video channel updated') |
431 | }) | 431 | }) |
432 | 432 | ||
433 | it('Should create the main channel with an uuid if there is a conflict', async function () { | 433 | it('Should create the main channel with a suffix if there is a conflict', async function () { |
434 | { | 434 | { |
435 | const videoChannel = { name: 'toto_channel', displayName: 'My toto channel' } | 435 | const videoChannel = { name: 'toto_channel', displayName: 'My toto channel' } |
436 | const created = await servers[0].channels.create({ attributes: videoChannel }) | 436 | const created = await servers[0].channels.create({ attributes: videoChannel }) |
@@ -442,8 +442,7 @@ describe('Test video channels', function () { | |||
442 | const accessToken = await servers[0].login.getAccessToken({ username: 'toto', password: 'password' }) | 442 | const accessToken = await servers[0].login.getAccessToken({ username: 'toto', password: 'password' }) |
443 | 443 | ||
444 | const { videoChannels } = await servers[0].users.getMyInfo({ token: accessToken }) | 444 | const { videoChannels } = await servers[0].users.getMyInfo({ token: accessToken }) |
445 | const videoChannel = videoChannels[0] | 445 | expect(videoChannels[0].name).to.equal('toto_channel-1') |
446 | expect(videoChannel.name).to.match(/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/) | ||
447 | } | 446 | } |
448 | }) | 447 | }) |
449 | 448 | ||
diff --git a/server/tests/fixtures/peertube-plugin-test-id-pass-auth-three/main.js b/server/tests/fixtures/peertube-plugin-test-id-pass-auth-three/main.js index caa6a7ccd..1200acfbd 100644 --- a/server/tests/fixtures/peertube-plugin-test-id-pass-auth-three/main.js +++ b/server/tests/fixtures/peertube-plugin-test-id-pass-auth-three/main.js | |||
@@ -32,7 +32,7 @@ async function register ({ | |||
32 | login (body) { | 32 | login (body) { |
33 | if (body.id === 'ward') { | 33 | if (body.id === 'ward') { |
34 | return Promise.resolve({ | 34 | return Promise.resolve({ |
35 | username: 'ward-42', | 35 | username: '-ward-42', |
36 | email: 'ward@example.com' | 36 | email: 'ward@example.com' |
37 | }) | 37 | }) |
38 | } | 38 | } |