Skip to content

Commit b185941

Browse files
committed
add tests
1 parent be77cb8 commit b185941

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

modules/typesniffer/typesniffer_test.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ func TestIsSvgImage(t *testing.T) {
6868
<!-- <svg></svg> inside comment -->
6969
<foo></foo>`)).IsSvgImage())
7070

71+
assert.False(t, DetectContentType([]byte(`<svg></svg><span></span>`)).IsSvgImage())
72+
assert.False(t, DetectContentType([]byte(`<svg></svg>text`)).IsSvgImage())
73+
7174
assert.False(t, DetectContentType([]byte(`
7275
<!-- comment1 -->
7376
<div>

0 commit comments

Comments
 (0)