X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Ftests%2Fapi%2Fvideos%2Fvideo-privacy.ts;h=b18c71c940d18b0d9dbd62fd9e2e5d8dc4fbaa4c;hb=8a6828b1664ce3fc535d23c54ed22bab35588d06;hp=3051a443d8eaae9d94d3bfc6875d5b677c6b1235;hpb=c3edc5b074aa4bb1861ed0a94d3713808e87170f;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/tests/api/videos/video-privacy.ts b/server/tests/api/videos/video-privacy.ts index 3051a443d..b18c71c94 100644 --- a/server/tests/api/videos/video-privacy.ts +++ b/server/tests/api/videos/video-privacy.ts @@ -1,13 +1,10 @@ /* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */ -import 'mocha' -import * as chai from 'chai' +import { expect } from 'chai' import { wait } from '@shared/core-utils' import { HttpStatusCode, VideoCreateResult, VideoPrivacy } from '@shared/models' import { cleanupTests, createSingleServer, doubleFollow, PeerTubeServer, setAccessTokensToServers, waitJobs } from '@shared/server-commands' -const expect = chai.expect - describe('Test video privacy', function () { const servers: PeerTubeServer[] = [] let anotherUserToken: string @@ -162,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 () {