(t *testing.T)
| 275 | } |
| 276 | |
| 277 | func 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 | |
| 293 | func TestGet_UnsupportedFormat(t *testing.T) { |
| 294 | tmpDir := createGetTestFiles(t) |
nothing calls this directly
no test coverage detected