(t *testing.T, s string)
| 34 | } |
| 35 | |
| 36 | func checkBalanced(t *testing.T, s string) { |
| 37 | t.Helper() |
| 38 | open := false |
| 39 | for i, c := range s { |
| 40 | if c == m.Start { |
| 41 | if open { |
| 42 | t.Errorf("unexpected open marker at position %d: %q", i, s) |
| 43 | return |
| 44 | } |
| 45 | open = true |
| 46 | } else if c == m.End { |
| 47 | if !open { |
| 48 | t.Errorf("unexpected close marker at position %d: %q", i, s) |
| 49 | return |
| 50 | } |
| 51 | open = false |
| 52 | } |
| 53 | } |
| 54 | if open { |
| 55 | t.Errorf("missing close marker at end of string: %q", s) |
| 56 | } |
| 57 | } |
| 58 | |
| 59 | func (b *Buffer) checkEqual(t *testing.T, expected string) { |
| 60 | t.Helper() |
no outgoing calls
no test coverage detected
searching dependent graphs…