test: extend timeout for single message (#911)

This commit is contained in:
Roman Zajic 2023-11-16 23:13:19 +08:00 committed by GitHub
parent b02a663e1b
commit c0aa5111a1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -118,7 +118,7 @@ func (s *FilterTestSuite) TestValidPayloadsSQL() {
func (s *FilterTestSuite) TestLargePayloadsUTF8() {
s.ctx, s.ctxCancel = context.WithTimeout(context.Background(), 20*time.Second)
s.ctx, s.ctxCancel = context.WithTimeout(context.Background(), 40*time.Second)
// Subscribe
s.subDetails = s.subscribe(s.testTopic, s.testContentTopic, s.fullNodeHost.ID())
@ -128,7 +128,7 @@ func (s *FilterTestSuite) TestLargePayloadsUTF8() {
// Generate large string
for i := range messages {
messages[i].payload, _ = tests.GenerateRandomUTF8String(1048576)
messages[i].payload, _ = tests.GenerateRandomUTF8String(153600)
s.log.Info("Generated payload with ", zap.String("length", strconv.Itoa(len(messages[i].payload))))
}

View File

@ -191,7 +191,7 @@ func (s *FilterTestSuite) waitForMessages(fn func(), subs []*subscription.Subscr
if matchOneOfManyMsg(received, expected) {
found++
}
case <-time.After(1 * time.Second):
case <-time.After(3 * time.Second):
case <-s.ctx.Done():
s.Require().Fail("test exceeded allocated time")