(t *testing.T)
| 9 | ) |
| 10 | |
| 11 | func TestFormatTimeDefault(t *testing.T) { |
| 12 | ts := time.Now().Add(-2 * time.Hour) |
| 13 | got := formatTime(ts, listOptions{}) |
| 14 | if got == "" { |
| 15 | t.Error("formatTime default returned empty") |
| 16 | } |
| 17 | if got == ts.Format(time.RFC3339) { |
| 18 | t.Error("default should be relative, not rfc3339") |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | func TestFormatTimeShort(t *testing.T) { |
| 23 | ts := time.Date(2025, 3, 15, 10, 30, 0, 0, time.UTC) |
nothing calls this directly
no test coverage detected