MCPcopy Create free account
hub / github.com/driangle/taskmd / TestContext_ExplicitOnly

Function TestContext_ExplicitOnly

apps/cli/internal/cli/context_test.go:182–200  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

180}
181
182func TestContext_ExplicitOnly(t *testing.T) {
183 tmpDir := createContextTestFiles(t)
184 resetContextFlags()
185 taskDir = tmpDir
186 setupTestConfig(t, tmpDir)
187
188 ctxTaskID = "002"
189 output, err := captureContextOutput(t)
190 if err != nil {
191 t.Fatalf("unexpected error: %v", err)
192 }
193
194 if !strings.Contains(output, "docs/readme.md") {
195 t.Errorf("expected docs/readme.md in output, got: %s", output)
196 }
197 if !strings.Contains(output, "Explicit files") {
198 t.Errorf("expected 'Explicit files' heading, got: %s", output)
199 }
200}
201
202func TestContext_BothSources(t *testing.T) {
203 tmpDir := createContextTestFiles(t)

Callers

nothing calls this directly

Calls 4

createContextTestFilesFunction · 0.85
resetContextFlagsFunction · 0.85
setupTestConfigFunction · 0.85
captureContextOutputFunction · 0.85

Tested by

no test coverage detected