| 186 | } |
| 187 | |
| 188 | func TestMinMaxHelpers(t *testing.T) { |
| 189 | // Test the min/max helper functions |
| 190 | if min(5, 10) != 5 { |
| 191 | t.Error("min(5, 10) should return 5") |
| 192 | } |
| 193 | if min(10, 5) != 5 { |
| 194 | t.Error("min(10, 5) should return 5") |
| 195 | } |
| 196 | if min(5, 5) != 5 { |
| 197 | t.Error("min(5, 5) should return 5") |
| 198 | } |
| 199 | |
| 200 | if max(5, 10) != 10 { |
| 201 | t.Error("max(5, 10) should return 10") |
| 202 | } |
| 203 | if max(10, 5) != 10 { |
| 204 | t.Error("max(10, 5) should return 10") |
| 205 | } |
| 206 | if max(5, 5) != 5 { |
| 207 | t.Error("max(5, 5) should return 5") |
| 208 | } |
| 209 | } |
| 210 | |
| 211 | func TestGetWorktreeInfo_NoBranch(t *testing.T) { |
| 212 | // No manager - should return empty |