aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEmmanuel Odeke <emm.odeke@gmail.com>2016-12-03 18:45:50 -0800
committerBrad Fitzpatrick <bradfitz@golang.org>2016-12-04 03:59:31 +0000
commitd54b60a2b2470ea42559b58995e86ff20dd70471 (patch)
tree9a7412019149eef4e405681a4d6e1fdbbf59bdd3 /src
parent37dbc7b49cbc9934c8dde54b65e5f417ce3faae9 (diff)
downloadgo-d54b60a2b2470ea42559b58995e86ff20dd70471.tar.xz
html/template: lock in application/json as valid JS test
CL https://go-review.googlesource.com/33899 added application/json as a mimeType for valid JS. Let's lock that fix in with a test. Updates #18159 Change-Id: Ic4dfd8929aebfc5410f796688f081ca06630f672 Reviewed-on: https://go-review.googlesource.com/33901 TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Nodir Turakulov <nodir@google.com> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src')
-rw-r--r--src/html/template/js_test.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/html/template/js_test.go b/src/html/template/js_test.go
index 58fc37ae3a..7484f60b54 100644
--- a/src/html/template/js_test.go
+++ b/src/html/template/js_test.go
@@ -341,6 +341,7 @@ func TestIsJsMimeType(t *testing.T) {
{"application/javascript;version=1.8;foo=bar", true},
{"application/javascript/version=1.8", false},
{"text/javascript", true},
+ {"application/json", true},
}
for _, test := range tests {