From 3ae8b8a99d6f36949c92e6ab6944cce166a9e19e Mon Sep 17 00:00:00 2001 From: Daniel Liu <139250065@qq.com> Date: Mon, 28 Apr 2025 10:47:39 +0800 Subject: [PATCH] rpc, internal/cmdtest: increase timeout in tests #27083 (#991) This change gives the cmd-tests have a bit more time to finish before getting forcibly torn down. Co-authored-by: Delweng --- internal/cmdtest/test_cmd.go | 2 +- rpc/client.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/cmdtest/test_cmd.go b/internal/cmdtest/test_cmd.go index 5369678adb..bbf77af016 100644 --- a/internal/cmdtest/test_cmd.go +++ b/internal/cmdtest/test_cmd.go @@ -226,7 +226,7 @@ func (tt *TestCmd) Kill() { } func (tt *TestCmd) withKillTimeout(fn func()) { - timeout := time.AfterFunc(5*time.Second, func() { + timeout := time.AfterFunc(30*time.Second, func() { tt.Log("killing the child process (timeout)") tt.Kill() }) diff --git a/rpc/client.go b/rpc/client.go index cf9bc7514c..c163e31b54 100644 --- a/rpc/client.go +++ b/rpc/client.go @@ -43,7 +43,7 @@ var ( const ( // Timeouts defaultDialTimeout = 10 * time.Second // used if context has no deadline - subscribeTimeout = 5 * time.Second // overall timeout eth_subscribe, rpc_modules calls + subscribeTimeout = 10 * time.Second // overall timeout eth_subscribe, rpc_modules calls ) const (