diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2006-12-21 15:23:59 +0000 |
---|---|---|
committer | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2006-12-21 15:23:59 +0000 |
commit | 98b1b580c7298c1ced00f9ec4d65452b4d559da7 (patch) | |
tree | f26cd06dc0345bbfa2439d4b62c2b308b08f68b9 /src/ajax/ajaxTest.js | |
parent | a0d5e89a1e41c8ebb1b629f6089e4f3b2cb24b2c (diff) | |
download | jquery-98b1b580c7298c1ced00f9ec4d65452b4d559da7.tar.gz jquery-98b1b580c7298c1ced00f9ec4d65452b4d559da7.zip |
A few corrections to the testsuite to imrove the failure testing
Diffstat (limited to 'src/ajax/ajaxTest.js')
-rw-r--r-- | src/ajax/ajaxTest.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/ajax/ajaxTest.js b/src/ajax/ajaxTest.js index ad85e0531..1cd072f9a 100644 --- a/src/ajax/ajaxTest.js +++ b/src/ajax/ajaxTest.js @@ -24,7 +24,7 @@ test("param", function() { test("pass-through request object", function() { expect(7); - stop(); + stop(true); var count = 0; var success = function() { if(count++ == 6) @@ -60,7 +60,7 @@ test("load(String, Object, Function) - simple: inject text into DOM", function() test("load(String, Object, Function) - inject without callback", function() { expect(1); - stop(); // check if load can be called with only url + stop(true); // check if load can be called with only url $('#first').load("data/name.php"); }); @@ -170,7 +170,7 @@ test("$.getScript(String, Function) - with callback", function() { test("$.getScript(String, Function) - no callback", function() { expect(1); - stop(); + stop(true); $.getScript("data/test.js"); }); @@ -319,15 +319,15 @@ test("$.ajax - xml: non-namespace elements inside namespaced elements", function test("$.ajax - beforeSend", function() { expect(1); stop(); - var customHeader = "value"; + var check = false; $.ajax({ url: "data/name.php", data: {'req': true}, beforeSend: function(xml) { - xml.setRequestHeader('X-Custom-Header', customHeader); + check = true }, success: function(data) { - ok( data == customHeader, "check return value, should be the custom header sent" ); + ok( check, "check beforeSend was executed" ); start(); } }); |