MCPcopy Create free account
hub / github.com/github/gh-aw / TestIsAMPMToken

Function TestIsAMPMToken

pkg/parser/schedule_time_utils_test.go:159–180  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

157}
158
159func TestIsAMPMToken(t *testing.T) {
160 tests := []struct {
161 input string
162 expected bool
163 }{
164 {"am", true},
165 {"AM", true},
166 {"pm", true},
167 {"PM", true},
168 {"Am", true},
169 {"Pm", true},
170 {"invalid", false},
171 {"", false},
172 }
173
174 for _, tt := range tests {
175 t.Run(tt.input, func(t *testing.T) {
176 result := isAMPMToken(tt.input)
177 assert.Equal(t, tt.expected, result, "isAMPMToken(%q) should return %v", tt.input, tt.expected)
178 })
179 }
180}
181
182func TestNormalizeTimezoneAbbreviation(t *testing.T) {
183 tests := []struct {

Callers

nothing calls this directly

Calls 2

isAMPMTokenFunction · 0.85
RunMethod · 0.45

Tested by

no test coverage detected