Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix build and lint
Signed-off-by: Spike Curtis <spike@coder.com>
  • Loading branch information
spikecurtis committed May 19, 2022
commit c62ae2f120f32f01d5dbebcb0659224caaa9a70a
3 changes: 1 addition & 2 deletions cli/delete_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,8 @@ import (
func TestDelete(t *testing.T) {
t.Run("WithParameter", func(t *testing.T) {
t.Parallel()
client := coderdtest.New(t, nil)
client := coderdtest.New(t, &coderdtest.Options{IncludeProvisionerD: true})
user := coderdtest.CreateFirstUser(t, client)
coderdtest.NewProvisionerDaemon(t, client)
version := coderdtest.CreateTemplateVersion(t, client, user.OrganizationID, nil)
coderdtest.AwaitTemplateVersionJob(t, client, version.ID)
template := coderdtest.CreateTemplate(t, client, user.OrganizationID, version.ID)
Expand Down
3 changes: 2 additions & 1 deletion cli/logout_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ package cli_test
import (
"testing"

"github.com/stretchr/testify/require"

"github.com/coder/coder/cli/clitest"
"github.com/coder/coder/coderd/coderdtest"
"github.com/coder/coder/pty/ptytest"
"github.com/stretchr/testify/require"
)

func TestLogout(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion cli/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ func server() *cobra.Command {
logger.Warn(cmd.Context(), "failed to start telemetry exporter", slog.Error(err))
} else {
defer func() {
// allow time for traces to flush even if command context is cancelled
// allow time for traces to flush even if command context is canceled
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second)
defer cancel()
_ = tracerProvider.Shutdown(ctx)
Expand Down
2 changes: 1 addition & 1 deletion coderd/coderd.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func newRouter(options *Options, a *api) chi.Router {
})
},
httpmw.Prometheus,
tracing.HTTPMW(api.TracerProvider, "coderd.http"),
tracing.HTTPMW(a.TracerProvider, "coderd.http"),
)

r.Route("/api/v2", func(r chi.Router) {
Expand Down