aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/misc-endpoints.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/misc-endpoints.ts')
-rw-r--r--server/tests/misc-endpoints.ts17
1 files changed, 5 insertions, 12 deletions
diff --git a/server/tests/misc-endpoints.ts b/server/tests/misc-endpoints.ts
index 84bdcaabf..b5b10bd5e 100644
--- a/server/tests/misc-endpoints.ts
+++ b/server/tests/misc-endpoints.ts
@@ -3,15 +3,8 @@
3import 'mocha' 3import 'mocha'
4import * as chai from 'chai' 4import * as chai from 'chai'
5import { HttpStatusCode } from '@shared/core-utils' 5import { HttpStatusCode } from '@shared/core-utils'
6import { 6import { cleanupTests, flushAndRunServer, makeGetRequest, ServerInfo, setAccessTokensToServers } from '@shared/extra-utils'
7 cleanupTests, 7import { VideoPrivacy } from '@shared/models'
8 flushAndRunServer,
9 makeGetRequest,
10 ServerInfo,
11 setAccessTokensToServers,
12 uploadVideo
13} from '../../shared/extra-utils'
14import { VideoPrivacy } from '../../shared/models/videos'
15 8
16const expect = chai.expect 9const expect = chai.expect
17 10
@@ -165,9 +158,9 @@ describe('Test misc endpoints', function () {
165 it('Should add videos, channel and accounts and get sitemap', async function () { 158 it('Should add videos, channel and accounts and get sitemap', async function () {
166 this.timeout(35000) 159 this.timeout(35000)
167 160
168 await uploadVideo(server.url, server.accessToken, { name: 'video 1', nsfw: false }) 161 await server.videosCommand.upload({ attributes: { name: 'video 1', nsfw: false } })
169 await uploadVideo(server.url, server.accessToken, { name: 'video 2', nsfw: false }) 162 await server.videosCommand.upload({ attributes: { name: 'video 2', nsfw: false } })
170 await uploadVideo(server.url, server.accessToken, { name: 'video 3', privacy: VideoPrivacy.PRIVATE }) 163 await server.videosCommand.upload({ attributes: { name: 'video 3', privacy: VideoPrivacy.PRIVATE } })
171 164
172 await server.channelsCommand.create({ attributes: { name: 'channel1', displayName: 'channel 1' } }) 165 await server.channelsCommand.create({ attributes: { name: 'channel1', displayName: 'channel 1' } })
173 await server.channelsCommand.create({ attributes: { name: 'channel2', displayName: 'channel 2' } }) 166 await server.channelsCommand.create({ attributes: { name: 'channel2', displayName: 'channel 2' } })