MCPcopy Create free account
hub / github.com/conventionalcommit/commitlint / TestFooterLeadingBlank_EmptyFooter_Pass

Function TestFooterLeadingBlank_EmptyFooter_Pass

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

Source from the content-addressed store, hash-verified

1136}
1137
1138func TestFooterLeadingBlank_EmptyFooter_Pass(t *testing.T) {
1139 r := &rule.FooterLeadingBlankRule{}
1140 if err := r.Apply(lint.RuleSetting{}); err != nil {
1141 t.Fatal(err)
1142 }
1143 _, ok := r.Validate(&mockCommit{footer: ""})
1144 if !ok {
1145 t.Error("empty footer should pass footer-leading-blank")
1146 }
1147}
1148
1149// ============================================================
1150// Header-trim rule

Callers

nothing calls this directly

Calls 3

ApplyMethod · 0.95
ValidateMethod · 0.95
ErrorMethod · 0.80

Tested by

no test coverage detected