aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/api/users
diff options
context:
space:
mode:
Diffstat (limited to 'server/tests/api/users')
-rw-r--r--server/tests/api/users/users.ts23
1 files changed, 20 insertions, 3 deletions
diff --git a/server/tests/api/users/users.ts b/server/tests/api/users/users.ts
index edb0b4bb3..fe83ca041 100644
--- a/server/tests/api/users/users.ts
+++ b/server/tests/api/users/users.ts
@@ -602,8 +602,8 @@ describe('Test users', function () {
602 expect(user.account.description).to.be.null 602 expect(user.account.description).to.be.null
603 }) 603 })
604 604
605 it('Should be able to update my avatar', async function () { 605 it('Should be able to update my avatar with a gif', async function () {
606 const fixture = 'avatar.png' 606 const fixture = 'avatar.gif'
607 607
608 await updateMyAvatar({ 608 await updateMyAvatar({
609 url: server.url, 609 url: server.url,
@@ -614,7 +614,24 @@ describe('Test users', function () {
614 const res = await getMyUserInformation(server.url, accessTokenUser) 614 const res = await getMyUserInformation(server.url, accessTokenUser)
615 const user = res.body 615 const user = res.body
616 616
617 await testImage(server.url, 'avatar-resized', user.account.avatar.path, '.png') 617 await testImage(server.url, 'avatar-resized', user.account.avatar.path, '.gif')
618 })
619
620 it('Should be able to update my avatar with a gif, and then a png', async function () {
621 for (const extension of [ '.png', '.gif' ]) {
622 const fixture = 'avatar' + extension
623
624 await updateMyAvatar({
625 url: server.url,
626 accessToken: accessTokenUser,
627 fixture
628 })
629
630 const res = await getMyUserInformation(server.url, accessTokenUser)
631 const user = res.body
632
633 await testImage(server.url, 'avatar-resized', user.account.avatar.path, extension)
634 }
618 }) 635 })
619 636
620 it('Should be able to update my display name', async function () { 637 it('Should be able to update my display name', async function () {