MCPcopy Index your code
hub / github.com/coder/coder / newFixture

Function newFixture

coderd/x/chatd/chatdebug/service_test.go:1067–1082  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

1065}
1066
1067func newFixture(t *testing.T) testFixture {
1068 t.Helper()
1069
1070 ctx := testutil.Context(t, testutil.WaitLong)
1071 db, _ := dbtestutil.NewDB(t)
1072 org, owner, chat, model := seedChat(t, db)
1073 return testFixture{
1074 ctx: ctx,
1075 db: db,
1076 svc: chatdebug.NewService(db, testutil.Logger(t), nil),
1077 org: org,
1078 owner: owner,
1079 chat: chat,
1080 model: model,
1081 }
1082}
1083
1084func seedChat(
1085 t *testing.T,

Calls 6

ContextFunction · 0.92
NewDBFunction · 0.92
NewServiceFunction · 0.92
LoggerFunction · 0.92
seedChatFunction · 0.85
HelperMethod · 0.65

Tested by

no test coverage detected