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

Function TestGet_YAMLFormat

apps/cli/internal/cli/get_test.go:277–291  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

275}
276
277func TestGet_YAMLFormat(t *testing.T) {
278 tmpDir := createGetTestFiles(t)
279 resetGetFlags()
280 taskDir = tmpDir
281 getFormat = "yaml"
282
283 output := captureGetOutput(t, "001")
284
285 expected := []string{"id: \"001\"", "title: Setup project", "status: completed"}
286 for _, exp := range expected {
287 if !strings.Contains(output, exp) {
288 t.Errorf("Expected YAML output to contain %q", exp)
289 }
290 }
291}
292
293func TestGet_UnsupportedFormat(t *testing.T) {
294 tmpDir := createGetTestFiles(t)

Callers

nothing calls this directly

Calls 3

createGetTestFilesFunction · 0.85
resetGetFlagsFunction · 0.85
captureGetOutputFunction · 0.85

Tested by

no test coverage detected