X-Git-Url: http://git.asbjorn.it/?a=blobdiff_plain;f=src%2Fjquery%2FcoreTest.js;h=4776a66eef4cb18a732d71f70dc3f390a06b894f;hb=ff4f265bc0273bda0c8873d470aefa20170abc41;hp=dc9c8ed48dfe2a501b9006d12afac3a11dd613a7;hpb=009033bb4566079c1f5006ca0e4521ad64117cd0;p=jquery.git diff --git a/src/jquery/coreTest.js b/src/jquery/coreTest.js index dc9c8ed..4776a66 100644 --- a/src/jquery/coreTest.js +++ b/src/jquery/coreTest.js @@ -12,7 +12,7 @@ test("Basic requirements", function() { }); test("$()", function() { - expect(3); + expect(4); var main = $("#main"); isSet( $("div p", main).get(), q("sndp", "en", "sap"), "Basic selector with jQuery object as context" ); @@ -32,6 +32,9 @@ test("$()", function() { pass = false; } ok( pass, "$('<tag>') needs optional document parameter to ease cross-frame DOM wrangling, see #968" ); + + var form = $("form")[0]; + equals( 15, $(form.elements).size(), "$(form.elements)" ); }); test("isFunction", function() { @@ -356,7 +359,7 @@ test("wrap(String|Element)", function() { }); test("append(String|Element|Array<Element>|jQuery)", function() { - expect(16); + expect(17); var defaultText = 'Try them out:' var result = $('#first').append('buga'); ok( result.text() == defaultText + 'buga', 'Check if text appending works' ); @@ -417,6 +420,13 @@ test("append(String|Element|Array<Element>|jQuery)", function() { $('#table colgroup').append('