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

Function TestLint_EmptyBodyAllowed

test/lint_test.go:289–298  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

287}
288
289func TestLint_EmptyBodyAllowed(t *testing.T) {
290 linter := newDefaultLinter(t)
291 result, err := linter.ParseAndLint("feat: add feature")
292 if err != nil {
293 t.Fatal(err)
294 }
295 if len(result.Issues()) != 0 {
296 t.Error("empty body should be allowed by default config")
297 }
298}
299
300// ---------------------------------------------------------------------------
301// Multiple issues in a single commit

Callers

nothing calls this directly

Calls 4

newDefaultLinterFunction · 0.85
ParseAndLintMethod · 0.80
IssuesMethod · 0.80
ErrorMethod · 0.80

Tested by

no test coverage detected