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

Commit5e9cbe8

Browse files
authored
chore(coderd): remove dbmem from tests (#18800)
Related to#15109.
1 parent66e4909 commit5e9cbe8

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

‎coderd/workspaceagents_test.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ import (
4646
"github.com/coder/coder/v2/coderd/database/dbauthz"
4747
"github.com/coder/coder/v2/coderd/database/dbfake"
4848
"github.com/coder/coder/v2/coderd/database/dbgen"
49-
"github.com/coder/coder/v2/coderd/database/dbmem"
5049
"github.com/coder/coder/v2/coderd/database/dbtestutil"
5150
"github.com/coder/coder/v2/coderd/database/dbtime"
5251
"github.com/coder/coder/v2/coderd/database/pubsub"
@@ -1989,8 +1988,8 @@ func (s *testWAMErrorStore) GetWorkspaceAgentMetadata(ctx context.Context, arg d
19891988
funcTestWorkspaceAgent_Metadata_CatchMemoryLeak(t*testing.T) {
19901989
t.Parallel()
19911990

1992-
db:=&testWAMErrorStore{Store:dbmem.New()}
1993-
psub:=pubsub.NewInMemory()
1991+
store,psub:=dbtestutil.NewDB(t)
1992+
db:=&testWAMErrorStore{Store:store}
19941993
logger:=slogtest.Make(t,&slogtest.Options{IgnoreErrors:true}).Named("coderd").Leveled(slog.LevelDebug)
19951994
client:=coderdtest.New(t,&coderdtest.Options{
19961995
Database:db,

‎coderd/workspaces_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import (
88
"fmt"
99
"math"
1010
"net/http"
11-
"os"
1211
"slices"
1312
"strings"
1413
"testing"
@@ -1426,9 +1425,6 @@ func TestWorkspaceByOwnerAndName(t *testing.T) {
14261425
// TestWorkspaceFilterAllStatus tests workspace status is correctly set given a set of conditions.
14271426
funcTestWorkspaceFilterAllStatus(t*testing.T) {
14281427
t.Parallel()
1429-
ifos.Getenv("DB")!="" {
1430-
t.Skip(`This test takes too long with an actual database. Takes 10s on local machine`)
1431-
}
14321428

14331429
// For this test, we do not care about permissions.
14341430
// nolint:gocritic // unit testing

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp