fix: handle backend issue list regressions
This commit is contained in:
@@ -488,6 +488,21 @@ func TestTopicAndSubscriptionCacheTTLIsShort(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestHotSeqExpectedCountUsesRangeSizeWhenSmallerThanLimit(t *testing.T) {
|
||||
if got := hotSeqExpectedCount(&types.QueryOpt{Since: 41, Before: 54, Limit: 20}, 20); got != 13 {
|
||||
t.Fatalf("expected range-sized count, got %d", got)
|
||||
}
|
||||
if got := hotSeqExpectedCount(&types.QueryOpt{Since: 41, Before: 80, Limit: 20}, 20); got != 20 {
|
||||
t.Fatalf("expected limit-sized count, got %d", got)
|
||||
}
|
||||
if got := hotSeqExpectedCount(&types.QueryOpt{Since: 0, Before: 54, Limit: 20}, 20); got != 20 {
|
||||
t.Fatalf("expected fallback limit count, got %d", got)
|
||||
}
|
||||
if got := hotSeqExpectedCount(nil, 20); got != 20 {
|
||||
t.Fatalf("expected nil opts limit count, got %d", got)
|
||||
}
|
||||
}
|
||||
|
||||
func TestInvalidateSubscriptionCacheWithZeroUserDeletesTopicPrefix(t *testing.T) {
|
||||
oldRuntime := groupMsgRuntime
|
||||
runtime := newTestGroupMessageRuntime()
|
||||
|
||||
Reference in New Issue
Block a user