MCPcopy Index your code
hub / github.com/go-git/go-git / TestMultipleTargets

Function TestMultipleTargets

utils/trace/trace_test.go:50–59  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

48}
49
50func TestMultipleTargets(t *testing.T) {
51 var buf bytes.Buffer
52 setUpTest(t, &buf)
53 SetTarget(General | Packet)
54 General.Print("a")
55 Packet.Print("b")
56 if buf.String() != "a\nb\n" {
57 t.Error("expected 'a\nb\n'")
58 }
59}
60
61func TestPrintf(t *testing.T) {
62 var buf bytes.Buffer

Callers

nothing calls this directly

Calls 5

SetTargetFunction · 0.85
PrintMethod · 0.80
setUpTestFunction · 0.70
StringMethod · 0.65
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…