diff options
| author | Claude Agent <agent@doot.local> | 2026-03-25 05:17:35 +0000 |
|---|---|---|
| committer | Claude Agent <agent@doot.local> | 2026-03-25 05:17:35 +0000 |
| commit | b58787cfec0bd07abc316c66dc9be6c10b8113c6 (patch) | |
| tree | e1c788094f51bdab0bce8ad38c8d6638c9079bb9 /internal/models/atom_test.go | |
| parent | 2db5020047640361066510f29f908ca9fd1c99aa (diff) | |
feat: add Claudomator stories as atom source in Doot tasks tab
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'internal/models/atom_test.go')
| -rw-r--r-- | internal/models/atom_test.go | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/internal/models/atom_test.go b/internal/models/atom_test.go index 70bc14b..53bf343 100644 --- a/internal/models/atom_test.go +++ b/internal/models/atom_test.go @@ -262,6 +262,37 @@ func TestTimelineItem_ComputeDaySection(t *testing.T) { } } +func TestStoryToAtom_Fields(t *testing.T) { + story := ClaudomatorStory{ + ID: "s1", + Title: "Fix auth", + Description: "desc", + Status: "IN_PROGRESS", + ProjectID: "nav", + } + + atom := StoryToAtom(story) + + if atom.Source != SourceClaudomator { + t.Errorf("Expected source 'claudomator', got '%s'", atom.Source) + } + if atom.SourceIcon != "🤖" { + t.Errorf("Expected SourceIcon '🤖', got '%s'", atom.SourceIcon) + } + if atom.ColorClass != "border-purple-500" { + t.Errorf("Expected ColorClass 'border-purple-500', got '%s'", atom.ColorClass) + } + if atom.Priority != 3 { + t.Errorf("Expected Priority 3, got %d", atom.Priority) + } + if atom.Title != "Fix auth" { + t.Errorf("Expected Title 'Fix auth', got '%s'", atom.Title) + } + if atom.Description != "desc [nav]" { + t.Errorf("Expected Description 'desc [nav]', got '%s'", atom.Description) + } +} + func TestCacheMetadata_IsCacheValid(t *testing.T) { t.Run("valid cache", func(t *testing.T) { cm := CacheMetadata{ |
