MM-34895: LastViewed should be updated correctly for new thread membership (#17673)

Summary
Update LastViewed correctly for new thread membership

Ticket Link
https://mattermost.atlassian.net/browse/MM-34895
Этот коммит содержится в:
Ashish Bhate
2021-05-25 18:51:42 +05:30
коммит произвёл GitHub
родитель 6f5e14dd5e
Коммит a95f90cec7
3 изменённых файлов: 16 добавлений и 7 удалений

Просмотреть файл

@@ -5766,8 +5766,8 @@ func TestMaintainUnreadRepliesInThread(t *testing.T) {
// replying to the thread clears reply count, so it should be 0
checkThreadListReplies(t, th, th.Client, th.BasicUser.Id, 0, 1, nil)
// the other user should have 2 replies
checkThreadListReplies(t, th, th.SystemAdminClient, th.SystemAdminUser.Id, 2, 1, nil)
// the other user should have 1 reply - the reply from the regular user
checkThreadListReplies(t, th, th.SystemAdminClient, th.SystemAdminUser.Id, 1, 1, nil)
// mark all as read for user
resp := th.Client.UpdateThreadsReadForUser(th.BasicUser.Id, th.BasicTeam.Id)