Skip to content

Commit

Permalink
fix(integration): waiting for node readiness
Browse files Browse the repository at this point in the history
Signed-off-by: gfanton <8671905+gfanton@users.noreply.github.com>
  • Loading branch information
gfanton committed Oct 19, 2023
1 parent 19cfdb0 commit 39152bf
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions gno.land/pkg/integration/testing_integration.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"strings"
"sync"
"testing"
"time"

"github.com/gnolang/gno/gno.land/pkg/gnoland"
"github.com/gnolang/gno/tm2/pkg/bft/config"
Expand Down Expand Up @@ -133,6 +134,12 @@ func SetupGnolandTestScript(t *testing.T, txtarDir string) testscript.Params {
}
})

select {
case <-time.After(time.Second * 6):
ts.Fatalf("timeout while waiting for the node to start")
case <-waitForNodeReadiness(node): // ok
}

// Register cleanup.
nodes[sid] = &testNode{
Node: node,
Expand Down

0 comments on commit 39152bf

Please sign in to comment.