Commit d5b1b754 authored by Inphi's avatar Inphi Committed by GitHub

op-e2e: Increase timeout of traceProvider.Get when moving (#10053)

The old 2 minute timeout is no longer sufficient. As cannon
execution sometimes requires more time to generate traces.
parent 211f9e4b
...@@ -11,6 +11,8 @@ import ( ...@@ -11,6 +11,8 @@ import (
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )
const getTraceTimeout = 10 * time.Minute
type OutputHonestHelper struct { type OutputHonestHelper struct {
t *testing.T t *testing.T
require *require.Assertions require *require.Assertions
...@@ -44,7 +46,7 @@ func (h *OutputHonestHelper) Attack(ctx context.Context, claimIdx int64, opts .. ...@@ -44,7 +46,7 @@ func (h *OutputHonestHelper) Attack(ctx context.Context, claimIdx int64, opts ..
// Ensure the claim exists // Ensure the claim exists
h.game.WaitForClaimCount(ctx, claimIdx+1) h.game.WaitForClaimCount(ctx, claimIdx+1)
ctx, cancel := context.WithTimeout(ctx, 2*time.Minute) ctx, cancel := context.WithTimeout(ctx, getTraceTimeout)
defer cancel() defer cancel()
game, claim := h.loadState(ctx, claimIdx) game, claim := h.loadState(ctx, claimIdx)
...@@ -61,7 +63,7 @@ func (h *OutputHonestHelper) Defend(ctx context.Context, claimIdx int64, opts .. ...@@ -61,7 +63,7 @@ func (h *OutputHonestHelper) Defend(ctx context.Context, claimIdx int64, opts ..
// Ensure the claim exists // Ensure the claim exists
h.game.WaitForClaimCount(ctx, claimIdx+1) h.game.WaitForClaimCount(ctx, claimIdx+1)
ctx, cancel := context.WithTimeout(ctx, 2*time.Minute) ctx, cancel := context.WithTimeout(ctx, getTraceTimeout)
defer cancel() defer cancel()
game, claim := h.loadState(ctx, claimIdx) game, claim := h.loadState(ctx, claimIdx)
defendPos := claim.Position.Defend() defendPos := claim.Position.Defend()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment