X-Git-Url: https://git.giacomolli.uk/onechat/blobdiff_plain/d7bc0a6ac452bfc646610fdfd7c8eccb5c55218f..6c7859cfea123479aba046614ee81028651ddaf5:/backup_test.go?ds=inline diff --git a/backup_test.go b/backup_test.go index 1638ed0..81fefd9 100644 --- a/backup_test.go +++ b/backup_test.go @@ -125,9 +125,10 @@ func TestBackupKeepsPendingNotificationsAndCompletedRetryReceipts(t *testing.T) require.NoError(t, test.loops[0].turn(t.Context())) _, err = test.messages.Notify(&NotifyInput{ - Source: "check", - ID: "pending", - Text: "A pending result.", + Source: "check", + ID: "pending", + AgentID: test.agents[1].agent.config.ID, + Text: "A pending result.", }) require.NoError(t, err) @@ -149,6 +150,7 @@ func TestBackupKeepsPendingNotificationsAndCompletedRetryReceipts(t *testing.T) recovered := newDaemonMessageTest(t, restored, server) require.Len(t, recovered.Queue(t).Pending, 1) + require.Equal(t, test.agents[1].agent.config.ID, recovered.Queue(t).Pending[0].TargetID) require.Len(t, recovered.Queue(t).Notifications, 2) duplicate, err := recovered.messages.Notify(&NotifyInput{