From: Jörn Zaefferer Date: Sat, 30 Sep 2006 14:34:49 +0000 (+0000) Subject: Refactored and fixed test suite to run async tests X-Git-Url: http://git.asbjorn.it/?a=commitdiff_plain;h=308d771dd1973015166f0ac3b6cc7d538f7911c4;p=jquery.git Refactored and fixed test suite to run async tests --- diff --git a/build/test/data/json.php b/build/test/data/json.php new file mode 100644 index 0000000..31668cf --- /dev/null +++ b/build/test/data/json.php @@ -0,0 +1,8 @@ + \ No newline at end of file diff --git a/build/test/data/name.php b/build/test/data/name.php new file mode 100644 index 0000000..a287fc9 --- /dev/null +++ b/build/test/data/name.php @@ -0,0 +1,22 @@ +$xml$result"; + die(); +} +$name = $_REQUEST['name']; +if($name == 'foo') { + echo "bar"; + die(); +} else if($name == 'peter') { + echo "pan"; + die(); +} +echo "ERROR"; +?> \ No newline at end of file diff --git a/build/test/data/test.js b/build/test/data/test.js new file mode 100644 index 0000000..2764fe1 --- /dev/null +++ b/build/test/data/test.js @@ -0,0 +1 @@ +foobar = "bar"; diff --git a/build/test/data/testrunner.js b/build/test/data/testrunner.js index db97215..11921f9 100644 --- a/build/test/data/testrunner.js +++ b/build/test/data/testrunner.js @@ -50,8 +50,8 @@ function runTest(tests) { } function test(name, callback) { - Test = []; synchronize(function() { + Test = []; try { callback(); } catch(e) { diff --git a/build/test/index.html b/build/test/index.html index 2124948..048eec1 100644 --- a/build/test/index.html +++ b/build/test/index.html @@ -34,9 +34,9 @@

Try them out:

    -
    - - + + + @@ -48,6 +48,8 @@ + +