diff options
author | Chocobozzz <me@florianbigard.com> | 2018-04-23 14:39:52 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-04-23 14:39:52 +0200 |
commit | 9d3ef9fe052ed29bd67566754cb28662bd122234 (patch) | |
tree | 7b704dbc0b2c8b4ca18bef2409d640d0019c3d0a /server/tests/api/check-params | |
parent | 2a2c19dfef7a9aa313c6ca0798f271c9a63449a9 (diff) | |
download | PeerTube-9d3ef9fe052ed29bd67566754cb28662bd122234.tar.gz PeerTube-9d3ef9fe052ed29bd67566754cb28662bd122234.tar.zst PeerTube-9d3ef9fe052ed29bd67566754cb28662bd122234.zip |
Use ISO 639 for languages
Diffstat (limited to 'server/tests/api/check-params')
-rw-r--r-- | server/tests/api/check-params/videos.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/server/tests/api/check-params/videos.ts b/server/tests/api/check-params/videos.ts index 1d19daa60..da41f515b 100644 --- a/server/tests/api/check-params/videos.ts +++ b/server/tests/api/check-params/videos.ts | |||
@@ -105,7 +105,7 @@ describe('Test videos API validator', function () { | |||
105 | name: 'my super name', | 105 | name: 'my super name', |
106 | category: 5, | 106 | category: 5, |
107 | licence: 1, | 107 | licence: 1, |
108 | language: 6, | 108 | language: 'pt', |
109 | nsfw: false, | 109 | nsfw: false, |
110 | commentsEnabled: true, | 110 | commentsEnabled: true, |
111 | description: 'my super description', | 111 | description: 'my super description', |
@@ -151,7 +151,7 @@ describe('Test videos API validator', function () { | |||
151 | }) | 151 | }) |
152 | 152 | ||
153 | it('Should fail with a bad language', async function () { | 153 | it('Should fail with a bad language', async function () { |
154 | const fields = immutableAssign(baseCorrectParams, { language: 125 }) | 154 | const fields = immutableAssign(baseCorrectParams, { language: 'a'.repeat(15) }) |
155 | const attaches = baseCorrectAttaches | 155 | const attaches = baseCorrectAttaches |
156 | 156 | ||
157 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) | 157 | await makeUploadRequest({ url: server.url, path: path + '/upload', token: server.accessToken, fields, attaches }) |
@@ -359,7 +359,7 @@ describe('Test videos API validator', function () { | |||
359 | name: 'my super name', | 359 | name: 'my super name', |
360 | category: 5, | 360 | category: 5, |
361 | licence: 2, | 361 | licence: 2, |
362 | language: 6, | 362 | language: 'pt', |
363 | nsfw: false, | 363 | nsfw: false, |
364 | commentsEnabled: false, | 364 | commentsEnabled: false, |
365 | description: 'my super description', | 365 | description: 'my super description', |
@@ -413,7 +413,7 @@ describe('Test videos API validator', function () { | |||
413 | }) | 413 | }) |
414 | 414 | ||
415 | it('Should fail with a bad language', async function () { | 415 | it('Should fail with a bad language', async function () { |
416 | const fields = immutableAssign(baseCorrectParams, { language: 125 }) | 416 | const fields = immutableAssign(baseCorrectParams, { language: 'a'.repeat(15) }) |
417 | 417 | ||
418 | await makePutBodyRequest({ url: server.url, path: path + videoId, token: server.accessToken, fields }) | 418 | await makePutBodyRequest({ url: server.url, path: path + videoId, token: server.accessToken, fields }) |
419 | }) | 419 | }) |