(t *testing.T)
| 299 | } |
| 300 | |
| 301 | func TestTaskToSnapshot_CoreOnly(t *testing.T) { |
| 302 | task := &model.Task{ |
| 303 | ID: "001", |
| 304 | Title: "Test", |
| 305 | Status: model.StatusPending, |
| 306 | Priority: model.PriorityHigh, |
| 307 | Effort: model.EffortSmall, |
| 308 | Group: "backend", |
| 309 | FilePath: "tasks/001.md", |
| 310 | } |
| 311 | taskMap := map[string]*model.Task{"001": task} |
| 312 | |
| 313 | snapshot := taskToSnapshot(task, true, false, nil, nil, nil, taskMap) |
| 314 | |
| 315 | if snapshot.ID != "001" { |
| 316 | t.Errorf("ID = %q, want %q", snapshot.ID, "001") |
| 317 | } |
| 318 | if snapshot.Title != "Test" { |
| 319 | t.Errorf("Title = %q, want %q", snapshot.Title, "Test") |
| 320 | } |
| 321 | // Core-only: status, priority, effort, group, filepath should be omitted |
| 322 | if snapshot.Status != "" { |
| 323 | t.Errorf("Status = %q, want empty (core-only mode)", snapshot.Status) |
| 324 | } |
| 325 | if snapshot.Priority != "" { |
| 326 | t.Errorf("Priority = %q, want empty (core-only mode)", snapshot.Priority) |
| 327 | } |
| 328 | if snapshot.FilePath != "" { |
| 329 | t.Errorf("FilePath = %q, want empty (core-only mode)", snapshot.FilePath) |
| 330 | } |
| 331 | } |
| 332 | |
| 333 | func TestTaskToSnapshot_WithDerived(t *testing.T) { |
| 334 | tasks := []*model.Task{ |
nothing calls this directly
no test coverage detected