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

Function TestSubscribeNonGitPathsIgnored

agent/agentgit/agentgit_test.go:84–93  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

82}
83
84func TestSubscribeNonGitPathsIgnored(t *testing.T) {
85 t.Parallel()
86
87 logger := slogtest.Make(t, nil)
88 h := agentgit.NewHandler(logger)
89
90 nonGitDir := t.TempDir()
91 added := h.Subscribe([]string{filepath.Join(nonGitDir, "file.txt")})
92 require.False(t, added, "non-git paths should be ignored")
93}
94
95func TestSubscribeRelativePathsIgnored(t *testing.T) {
96 t.Parallel()

Callers

nothing calls this directly

Calls 3

SubscribeMethod · 0.95
NewHandlerFunction · 0.92
TempDirMethod · 0.65

Tested by

no test coverage detected