Fix error handling when requesting profile image for bad user ID (#8618)

This commit is contained in:
Joram Wilander
2018-04-13 07:57:22 -07:00
committed by Christopher Speller
parent ae5e324be8
commit 21b1cd44e0
3 changed files with 9 additions and 1 deletions
+3
View File
@@ -834,6 +834,9 @@ func TestGetProfileImage(t *testing.T) {
_, resp = Client.GetProfileImage("junk", "")
CheckBadRequestStatus(t, resp)
_, resp = Client.GetProfileImage(model.NewId(), "")
CheckNotFoundStatus(t, resp)
Client.Logout()
_, resp = Client.GetProfileImage(user.Id, "")
CheckUnauthorizedStatus(t, resp)