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

Function TestConfig_GetFormatter

test/config_test.go:53–65  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

51}
52
53func TestConfig_GetFormatter(t *testing.T) {
54 conf := config.NewDefault()
55 f, err := config.GetFormatter(conf)
56 if err != nil {
57 t.Fatalf("unexpected error: %v", err)
58 }
59 if f == nil {
60 t.Fatal("expected non-nil formatter")
61 }
62 if f.Name() != "default" {
63 t.Errorf("expected formatter name 'default', got %q", f.Name())
64 }
65}
66
67func TestConfig_GetFormatterJSON(t *testing.T) {
68 conf := config.NewDefault()

Callers

nothing calls this directly

Calls 3

NewDefaultFunction · 0.92
GetFormatterFunction · 0.92
NameMethod · 0.65

Tested by

no test coverage detected