Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit33dbd92

Browse files
committed
linting
1 parent685b21e commit33dbd92

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

‎coderd/database/dbtestutil/tx.go‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ import (
44
"sync"
55
"testing"
66

7+
"github.com/stretchr/testify/assert"
8+
"golang.org/x/xerrors"
9+
710
"github.com/coder/coder/v2/coderd/database"
811
)
912

@@ -44,7 +47,7 @@ func StartTx(t *testing.T, db database.Store, opts *database.TxOptions) *DBTx {
4447
ifcount>1 {
4548
// If you recursively call InTx, then don't use this.
4649
t.Logf("InTx called more than once: %d",count)
47-
t.Fatal("InTx called more than once, this is not allowed with the StartTx helper")
50+
assert.NoError(t,xerrors.New("InTx called more than once, this is not allowed with the StartTx helper"))
4851
}
4952

5053
<-done

‎enterprise/coderd/workspacequota_test.go‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -886,9 +886,3 @@ func (c *committer) UpdateWorkspaceBuildCostByID(ctx context.Context, t *testing
886886
func (c*committer)Done()error {
887887
returnc.DBTx.Done()
888888
}
889-
890-
funcnoReturn[Tany](ffunc(context.Context,*testing.T)T)func(context.Context,*testing.T) {
891-
returnfunc(ctx context.Context,t*testing.T) {
892-
f(ctx,t)
893-
}
894-
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp