X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=test%2Funit%2Fajax.js;h=f6809d539e5ded464c952946099f44dd9001978e;hb=ca90ffb332eafc93b8107aeb2afa7473132392fd;hp=195fa27ca4bed06cac80cf1474a8881af0260381;hpb=bed759c95ca6d796125653b540e8611dc63b38bb;p=jquery.git diff --git a/test/unit/ajax.js b/test/unit/ajax.js index 195fa27..f6809d5 100644 --- a/test/unit/ajax.js +++ b/test/unit/ajax.js @@ -892,7 +892,7 @@ test("jQuery.ajax() - script, Remote with scheme-less URL", function() { }); test("jQuery.ajax() - malformed JSON", function() { - expect(1); + expect(2); stop(); @@ -903,8 +903,9 @@ test("jQuery.ajax() - malformed JSON", function() { ok( false, "Success." ); start(); }, - error: function(xhr, msg) { + error: function(xhr, msg, detailedMsg) { equals( "parsererror", msg, "A parse error occurred." ); + ok( /^Invalid JSON/.test(detailedMsg), "Detailed parsererror message provided" ); start(); } });