blob: 48ab9c2f93c74ffa75a488c84289bf7653bce3c8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
package command
import (
"testing"
"github.com/stretchr/testify/require"
"gitlab.com/gitlab-org/gitaly/v15/internal/testhelper"
)
func TestGetSpawnToken_CommandStats(t *testing.T) {
ctx := testhelper.Context(t)
ctx = InitContextStats(ctx)
putToken, err := getSpawnToken(ctx)
require.Nil(t, err)
putToken()
stats := StatsFromContext(ctx)
require.NotNil(t, stats)
require.Contains(t, stats.Fields(), "command.spawn_token_wait_ms")
}
|