MCPcopy Index your code
hub / github.com/conventionalcommit/commitlint / TestFooterMaxLineLen_Pass

Function TestFooterMaxLineLen_Pass

test/rule_test.go:206–215  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

204}
205
206func TestFooterMaxLineLen_Pass(t *testing.T) {
207 r := &rule.FooterMaxLineLenRule{}
208 if err := r.Apply(lint.RuleSetting{Argument: 72}); err != nil {
209 t.Fatal(err)
210 }
211 _, ok := r.Validate(&mockCommit{footer: "Fixes: #123\nReviewed-by: John"})
212 if !ok {
213 t.Error("footer lines <= 72 should pass")
214 }
215}
216
217func TestFooterMaxLineLen_Fail(t *testing.T) {
218 r := &rule.FooterMaxLineLenRule{}

Callers

nothing calls this directly

Calls 3

ApplyMethod · 0.95
ValidateMethod · 0.95
ErrorMethod · 0.80

Tested by

no test coverage detected