aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/users/users.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-09-26 16:28:15 +0200
committerChocobozzz <me@florianbigard.com>2018-09-26 16:28:27 +0200
commita890d1e0d30851741392e6e7f14acffe685d28e0 (patch)
tree40f6d0c4643f795670943e176d60b2e85a0fb6e0 /server/tests/api/users/users.ts
parentbe1206bb934c223893a652be5f1f6c911c9c66be (diff)
downloadPeerTube-a890d1e0d30851741392e6e7f14acffe685d28e0.tar.gz
PeerTube-a890d1e0d30851741392e6e7f14acffe685d28e0.tar.zst
PeerTube-a890d1e0d30851741392e6e7f14acffe685d28e0.zip
Check current password on server side
Diffstat (limited to 'server/tests/api/users/users.ts')
-rw-r--r--server/tests/api/users/users.ts33
1 files changed, 29 insertions, 4 deletions
diff --git a/server/tests/api/users/users.ts b/server/tests/api/users/users.ts
index c0dd587ee..8b9c6b455 100644
--- a/server/tests/api/users/users.ts
+++ b/server/tests/api/users/users.ts
@@ -4,10 +4,34 @@ import * as chai from 'chai'
4import 'mocha' 4import 'mocha'
5import { User, UserRole } from '../../../../shared/index' 5import { User, UserRole } from '../../../../shared/index'
6import { 6import {
7 createUser, flushTests, getBlacklistedVideosList, getMyUserInformation, getMyUserVideoQuotaUsed, getMyUserVideoRating, 7 blockUser,
8 getUserInformation, getUsersList, getUsersListPaginationAndSort, getVideosList, killallServers, login, makePutBodyRequest, rateVideo, 8 createUser,
9 registerUser, removeUser, removeVideo, runServer, ServerInfo, testImage, updateMyAvatar, updateMyUser, updateUser, uploadVideo, userLogin, 9 deleteMe,
10 deleteMe, blockUser, unblockUser, updateCustomSubConfig 10 flushTests,
11 getBlacklistedVideosList,
12 getMyUserInformation,
13 getMyUserVideoQuotaUsed,
14 getMyUserVideoRating,
15 getUserInformation,
16 getUsersList,
17 getUsersListPaginationAndSort,
18 getVideosList,
19 killallServers,
20 login,
21 makePutBodyRequest,
22 rateVideo,
23 registerUser,
24 removeUser,
25 removeVideo,
26 runServer,
27 ServerInfo,
28 testImage,
29 unblockUser,
30 updateMyAvatar,
31 updateMyUser,
32 updateUser,
33 uploadVideo,
34 userLogin
11} from '../../utils/index' 35} from '../../utils/index'
12import { follow } from '../../utils/server/follows' 36import { follow } from '../../utils/server/follows'
13import { setAccessTokensToServers } from '../../utils/users/login' 37import { setAccessTokensToServers } from '../../utils/users/login'
@@ -302,6 +326,7 @@ describe('Test users', function () {
302 await updateMyUser({ 326 await updateMyUser({
303 url: server.url, 327 url: server.url,
304 accessToken: accessTokenUser, 328 accessToken: accessTokenUser,
329 currentPassword: 'super password',
305 newPassword: 'new password' 330 newPassword: 'new password'
306 }) 331 })
307 user.password = 'new password' 332 user.password = 'new password'