summaryrefslogtreecommitdiff
path: root/share/www/script/test/content_negotiation.js
diff options
context:
space:
mode:
Diffstat (limited to 'share/www/script/test/content_negotiation.js')
-rw-r--r--share/www/script/test/content_negotiation.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/share/www/script/test/content_negotiation.js b/share/www/script/test/content_negotiation.js
index 757105ff..9df79bcd 100644
--- a/share/www/script/test/content_negotiation.js
+++ b/share/www/script/test/content_negotiation.js
@@ -20,6 +20,10 @@ couchTests.content_negotiation = function(debug) {
xhr = CouchDB.request("GET", "/test_suite_db/");
T(xhr.getResponseHeader("Content-Type") == "text/plain;charset=utf-8");
+ // make sure JSON responses end in a newline
+ var text = xhr.responseText;
+ T(text[text.length-1] == "\n");
+
xhr = CouchDB.request("GET", "/test_suite_db/", {
headers: {"Accept": "text/html;text/plain;*/*"}
});