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

Function TestFooterEmptyRule_EmptyFails

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

Source from the content-addressed store, hash-verified

913}
914
915func TestFooterEmptyRule_EmptyFails(t *testing.T) {
916 r := &rule.FooterEmptyRule{}
917 if err := r.Apply(lint.RuleSetting{}); err != nil {
918 t.Fatal(err)
919 }
920 _, ok := r.Validate(&mockCommit{footer: ""})
921 if ok {
922 t.Error("empty footer should fail footer-empty rule")
923 }
924}
925
926func TestDescriptionEmptyRule_NonEmptyPasses(t *testing.T) {
927 r := &rule.DescriptionEmptyRule{}

Callers

nothing calls this directly

Calls 3

ApplyMethod · 0.95
ValidateMethod · 0.95
ErrorMethod · 0.80

Tested by

no test coverage detected