diff options
author | Chocobozzz <me@florianbigard.com> | 2021-10-20 09:05:43 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-10-20 09:25:44 +0200 |
commit | 978c87e7f58b6673fe60f04f1767bc9e02ea4936 (patch) | |
tree | e7d48735d4099fec8c7732f33e7dadb09c0eac80 /server/tests/api/check-params | |
parent | 7e76cc380040e40a2292a9dc825f037c9b538030 (diff) | |
download | PeerTube-978c87e7f58b6673fe60f04f1767bc9e02ea4936.tar.gz PeerTube-978c87e7f58b6673fe60f04f1767bc9e02ea4936.tar.zst PeerTube-978c87e7f58b6673fe60f04f1767bc9e02ea4936.zip |
Add channel filters for my videos/followers
Diffstat (limited to 'server/tests/api/check-params')
-rw-r--r-- | server/tests/api/check-params/videos.ts | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/server/tests/api/check-params/videos.ts b/server/tests/api/check-params/videos.ts index e11ca0c82..d02b6e156 100644 --- a/server/tests/api/check-params/videos.ts +++ b/server/tests/api/check-params/videos.ts | |||
@@ -119,6 +119,20 @@ describe('Test videos API validator', function () { | |||
119 | await checkBadSortPagination(server.url, path, server.accessToken) | 119 | await checkBadSortPagination(server.url, path, server.accessToken) |
120 | }) | 120 | }) |
121 | 121 | ||
122 | it('Should fail with an invalid channel', async function () { | ||
123 | await makeGetRequest({ url: server.url, token: server.accessToken, path, query: { channelId: 'toto' } }) | ||
124 | }) | ||
125 | |||
126 | it('Should fail with an unknown channel', async function () { | ||
127 | await makeGetRequest({ | ||
128 | url: server.url, | ||
129 | token: server.accessToken, | ||
130 | path, | ||
131 | query: { channelId: 89898 }, | ||
132 | expectedStatus: HttpStatusCode.NOT_FOUND_404 | ||
133 | }) | ||
134 | }) | ||
135 | |||
122 | it('Should success with the correct parameters', async function () { | 136 | it('Should success with the correct parameters', async function () { |
123 | await makeGetRequest({ url: server.url, token: server.accessToken, path, expectedStatus: HttpStatusCode.OK_200 }) | 137 | await makeGetRequest({ url: server.url, token: server.accessToken, path, expectedStatus: HttpStatusCode.OK_200 }) |
124 | }) | 138 | }) |