A bunch of comments from review

This commit is contained in:
David Robertson 2023-09-20 13:56:33 +01:00
parent 507b2622b9
commit ed7f052682
No known key found for this signature in database
GPG Key ID: 903ECE108A39DEDD
2 changed files with 5 additions and 2 deletions

View File

@ -128,7 +128,8 @@ func NewEventTable(db *sqlx.DB) *EventTable {
membership TEXT,
is_state BOOLEAN NOT NULL, -- is this event part of the v2 state response?
event BYTEA NOT NULL,
-- True iff the previous timeline event is not known to the proxy.
-- True iff this event was seen at the start of the timeline in a limited sync
-- (i.e. the preceding timeline event was not known to the proxy).
missing_previous BOOLEAN NOT NULL DEFAULT FALSE
);

View File

@ -1169,7 +1169,9 @@ func TestEventTable_SelectLatestEventsBetween_MissingPrevious(t *testing.T) {
Desc string
FromIDExclusive string
ToIDInclusive string
ExpectIDs []string
// NB: ExpectIDs is ordered from newest to oldest. Surprising, but this is what
// SelectLatestEventsBetween returns.
ExpectIDs []string
}{
{
Desc: "has no gaps - should omit nothing",