X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Ftests%2Fapi%2Fvideos%2Fvideo-privacy.ts;h=b18c71c940d18b0d9dbd62fd9e2e5d8dc4fbaa4c;hb=8a6828b1664ce3fc535d23c54ed22bab35588d06;hp=13eb941eae45c23439eb64d9a1c4f0c2f4da8cc4;hpb=bf54587a3e2ad9c2c186828f2a5682b91ee2cc00;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/tests/api/videos/video-privacy.ts b/server/tests/api/videos/video-privacy.ts index 13eb941ea..b18c71c94 100644 --- a/server/tests/api/videos/video-privacy.ts +++ b/server/tests/api/videos/video-privacy.ts @@ -1,19 +1,9 @@ /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ -import 'mocha' -import * as chai from 'chai' -import { - cleanupTests, - createSingleServer, - doubleFollow, - PeerTubeServer, - setAccessTokensToServers, - wait, - waitJobs -} from '@shared/server-commands' +import { expect } from 'chai' +import { wait } from '@shared/core-utils' import { HttpStatusCode, VideoCreateResult, VideoPrivacy } from '@shared/models' - -const expect = chai.expect +import { cleanupTests, createSingleServer, doubleFollow, PeerTubeServer, setAccessTokensToServers, waitJobs } from '@shared/server-commands' describe('Test video privacy', function () { const servers: PeerTubeServer[] = [] @@ -169,7 +159,7 @@ describe('Test video privacy', function () { }) it('Should not be able to get this unlisted video using its id', async function () { - await servers[1].videos.get({ id: unlistedVideo.id, expectedStatus: HttpStatusCode.NOT_FOUND_404 }) + await servers[1].videos.get({ id: unlistedVideo.id, expectedStatus: HttpStatusCode.UNAUTHORIZED_401 }) }) it('Should be able to get this unlisted video using its uuid/shortUUID', async function () {