Implement some team endpoints for APIv4 (#5745)
* Implement PUT /teams/{team_id} endpoint for APIv4
* Implement GET /users/{user_id}/teams/{team_id}/unread endpoint for APIv4
* Implement POST /teams/{team_id}/members/ids endpoint for APIv4
* Remove debug statement
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
5ec49c0db0
Коммит
a284cd8c18
@@ -41,3 +41,17 @@ func TestTeamMemberIsValid(t *testing.T) {
|
||||
t.Fatal(err)
|
||||
}*/
|
||||
}
|
||||
|
||||
func TestUnreadMemberJson(t *testing.T) {
|
||||
o := TeamUnread{TeamId: NewId(), MsgCount: 5, MentionCount: 3}
|
||||
json := o.ToJson()
|
||||
|
||||
r := TeamUnreadFromJson(strings.NewReader(json))
|
||||
if o.TeamId != r.TeamId {
|
||||
t.Fatal("Ids do not match")
|
||||
}
|
||||
|
||||
if o.MsgCount != r.MsgCount {
|
||||
t.Fatal("MsgCount do not match")
|
||||
}
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user