(t *testing.T)
| 13 | } |
| 14 | |
| 15 | func TestToTextParagraphs(t *testing.T) { |
| 16 | got := ToText("<p>First</p><p>Second</p>") |
| 17 | if !strings.Contains(got, "First") || !strings.Contains(got, "Second") { |
| 18 | t.Errorf("ToText paragraphs = %q, should contain First and Second", got) |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | func TestToTextBr(t *testing.T) { |
| 23 | got := ToText("line1<br>line2") |