aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/check-params
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-05-28 10:21:39 +0200
committerChocobozzz <me@florianbigard.com>2021-05-28 10:22:50 +0200
commit012580d98f489e599d44a9a2a0bdc892b9455a90 (patch)
treecd6d4abdbf43f4cd1c051ac49682b97c7b6dca92 /server/tests/api/check-params
parentd6d96bed80700830063c6055969d2d2ff46c63c6 (diff)
downloadPeerTube-012580d98f489e599d44a9a2a0bdc892b9455a90.tar.gz
PeerTube-012580d98f489e599d44a9a2a0bdc892b9455a90.tar.zst
PeerTube-012580d98f489e599d44a9a2a0bdc892b9455a90.zip
Cleanup
We must not expose private actor objects to clients Just make 2 GET requests on channel/accounts instead
Diffstat (limited to 'server/tests/api/check-params')
-rw-r--r--server/tests/api/check-params/actors.ts37
1 files changed, 0 insertions, 37 deletions
diff --git a/server/tests/api/check-params/actors.ts b/server/tests/api/check-params/actors.ts
deleted file mode 100644
index 3a03edc39..000000000
--- a/server/tests/api/check-params/actors.ts
+++ /dev/null
@@ -1,37 +0,0 @@
1/* eslint-disable @typescript-eslint/no-unused-expressions,@typescript-eslint/require-await */
2
3import 'mocha'
4
5import { cleanupTests, flushAndRunServer, ServerInfo } from '../../../../shared/extra-utils'
6import { getActor } from '../../../../shared/extra-utils/actors/actors'
7import { HttpStatusCode } from '../../../../shared/core-utils/miscs/http-error-codes'
8
9describe('Test actors API validators', function () {
10 let server: ServerInfo
11
12 // ---------------------------------------------------------------
13
14 before(async function () {
15 this.timeout(30000)
16
17 server = await flushAndRunServer(1)
18 })
19
20 describe('When getting an actor', function () {
21 it('Should return 404 with a non existing actorName', async function () {
22 await getActor(server.url, 'arfaze', HttpStatusCode.NOT_FOUND_404)
23 })
24
25 it('Should return 200 with an existing accountName', async function () {
26 await getActor(server.url, 'root', HttpStatusCode.OK_200)
27 })
28
29 it('Should return 200 with an existing channelName', async function () {
30 await getActor(server.url, 'root_channel', HttpStatusCode.OK_200)
31 })
32 })
33
34 after(async function () {
35 await cleanupTests([ server ])
36 })
37})