User: Add tracing (#87028)
* Inject tracer in tests * Annotate with traces Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
This commit is contained in:
co-authored by
Gabriel MABILLE
parent
7f1b2ef205
commit
a2cba3d0b5
@@ -9,6 +9,7 @@ import (
|
||||
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"github.com/grafana/grafana/pkg/infra/tracing"
|
||||
"github.com/grafana/grafana/pkg/server"
|
||||
"github.com/grafana/grafana/pkg/services/correlations"
|
||||
"github.com/grafana/grafana/pkg/services/datasources"
|
||||
@@ -160,7 +161,10 @@ func (c TestContext) createUser(cmd user.CreateUserCommand) User {
|
||||
quotaService := quotaimpl.ProvideService(store, c.env.Cfg)
|
||||
orgService, err := orgimpl.ProvideService(store, c.env.Cfg, quotaService)
|
||||
require.NoError(c.t, err)
|
||||
usrSvc, err := userimpl.ProvideService(store, orgService, c.env.Cfg, nil, nil, quotaService, supportbundlestest.NewFakeBundleService())
|
||||
usrSvc, err := userimpl.ProvideService(
|
||||
store, orgService, c.env.Cfg, nil, nil, tracing.InitializeTracerForTest(),
|
||||
quotaService, supportbundlestest.NewFakeBundleService(),
|
||||
)
|
||||
require.NoError(c.t, err)
|
||||
|
||||
user, err := usrSvc.Create(context.Background(), &cmd)
|
||||
|
||||
Reference in New Issue
Block a user