package badge import ( "encoding/base64" "strings" "testing" "gno.land/p/nt/uassert/v0" "gno.land/p/nt/urequire/v0" ) func TestSVG(t *testing.T) { s := SVG("bouncer", "A 96", Green) uassert.True(t, strings.HasPrefix(s, `A 96`)) // width = (7*7+16) + (4*7+16) = 65 + 44 uassert.True(t, strings.Contains(s, `width="109" height="20"`)) } func TestSVGEscapesAndClips(t *testing.T) { s := SVG(`