diff options
Diffstat (limited to 'server/tests/api/check-params/videos-history.ts')
-rw-r--r-- | server/tests/api/check-params/videos-history.ts | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/server/tests/api/check-params/videos-history.ts b/server/tests/api/check-params/videos-history.ts index 0e91fe0a8..1da922a17 100644 --- a/server/tests/api/check-params/videos-history.ts +++ b/server/tests/api/check-params/videos-history.ts | |||
@@ -1,6 +1,7 @@ | |||
1 | /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ | 1 | /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ |
2 | 2 | ||
3 | import 'mocha' | 3 | import 'mocha' |
4 | import { HttpStatusCode } from '@shared/core-utils' | ||
4 | import { | 5 | import { |
5 | checkBadCountPagination, | 6 | checkBadCountPagination, |
6 | checkBadStartPagination, | 7 | checkBadStartPagination, |
@@ -10,10 +11,8 @@ import { | |||
10 | makePostBodyRequest, | 11 | makePostBodyRequest, |
11 | makePutBodyRequest, | 12 | makePutBodyRequest, |
12 | ServerInfo, | 13 | ServerInfo, |
13 | setAccessTokensToServers, | 14 | setAccessTokensToServers |
14 | uploadVideo | 15 | } from '@shared/extra-utils' |
15 | } from '../../../../shared/extra-utils' | ||
16 | import { HttpStatusCode } from '../../../../shared/core-utils/miscs/http-error-codes' | ||
17 | 16 | ||
18 | describe('Test videos history API validator', function () { | 17 | describe('Test videos history API validator', function () { |
19 | const myHistoryPath = '/api/v1/users/me/history/videos' | 18 | const myHistoryPath = '/api/v1/users/me/history/videos' |
@@ -30,10 +29,8 @@ describe('Test videos history API validator', function () { | |||
30 | 29 | ||
31 | await setAccessTokensToServers([ server ]) | 30 | await setAccessTokensToServers([ server ]) |
32 | 31 | ||
33 | const res = await uploadVideo(server.url, server.accessToken, {}) | 32 | const { uuid } = await server.videosCommand.upload() |
34 | const videoUUID = res.body.video.uuid | 33 | watchingPath = '/api/v1/videos/' + uuid + '/watching' |
35 | |||
36 | watchingPath = '/api/v1/videos/' + videoUUID + '/watching' | ||
37 | }) | 34 | }) |
38 | 35 | ||
39 | describe('When notifying a user is watching a video', function () { | 36 | describe('When notifying a user is watching a video', function () { |