Skip to content

Commit c544481

Browse files
authored
Longer timeout for install part of e2e test (#157)
1 parent 2b45b4e commit c544481

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

e2e_test.go

+11-5
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ import (
1313
)
1414

1515
const (
16-
startTimeout = 5 * time.Second
17-
testTimeout = 15 * time.Second
16+
installTimeout = 30 * time.Second
17+
startTimeout = 5 * time.Second
18+
testTimeout = 15 * time.Second
1819
)
1920

2021
func TestEndToEndTrustlessGatewayDomains(t *testing.T) {
@@ -23,18 +24,23 @@ func TestEndToEndTrustlessGatewayDomains(t *testing.T) {
2324
t.Skip("skipping test on", runtime.GOOS)
2425
}
2526

26-
ctx, cancel := context.WithTimeout(context.Background(), testTimeout)
27-
defer cancel()
28-
2927
runner := testcmd.NewRunner(t, t.TempDir())
3028

29+
ctx, cancel := context.WithTimeout(context.Background(), installTimeout)
30+
defer cancel()
31+
3132
// install rainbow
3233
runner.Run(ctx, "go", "install", ".")
34+
cancel()
3335
rainbow := filepath.Join(runner.Dir, "rainbow")
3436

3537
args := testcmd.Args(rainbow, "--trustless-gateway-domains", "example.org")
3638
ready := testcmd.NewStdoutWatcher("IPFS Gateway listening")
3739
domain := testcmd.NewStdoutWatcher("RAINBOW_TRUSTLESS_GATEWAY_DOMAINS = example.org")
40+
41+
ctx, cancel = context.WithTimeout(context.Background(), testTimeout)
42+
defer cancel()
43+
3844
cmdRainbow := runner.Start(ctx, args, ready, domain)
3945

4046
startCtx, startCancel := context.WithTimeout(context.Background(), startTimeout)

0 commit comments

Comments
 (0)