Add /api/v1/notifications/dismiss

This commit is contained in:
buckket 2019-05-16 01:59:33 +02:00
parent f51571807d
commit 345ee46682
No known key found for this signature in database
GPG key ID: 06C09618D395A6CD
3 changed files with 20 additions and 0 deletions

View file

@ -20,6 +20,9 @@ func TestGetNotifications(t *testing.T) {
case "/api/v1/notifications/clear":
fmt.Fprintln(w, `{}`)
return
case "/api/v1/notifications/dismiss":
fmt.Fprintln(w, `{}`)
return
}
http.Error(w, http.StatusText(http.StatusNotFound), http.StatusNotFound)
return
@ -56,4 +59,8 @@ func TestGetNotifications(t *testing.T) {
if err != nil {
t.Fatalf("should not be fail: %v", err)
}
err = client.DismissNotification(context.Background(), "123")
if err != nil {
t.Fatalf("should not be fail: %v", err)
}
}