package email
import (
"strings"
"testing"
)
func TestSanitizeHTML(t *testing.T) {
cid := map[string]string{"logo@x": "data:image/png;base64,AAAA"}
tests := []struct {
name string
input string
allowRemote bool
contains []string
absent []string
remote bool
}{
{
name: "script and handlers removed",
input: `
Hi
`,
absent: []string{"onclick", "onmouseover", "ok`,
absent: []string{"