X-Git-Url: http://git.asbjorn.it/?a=blobdiff_plain;ds=sidebyside;f=src%2Fjquery%2FcoreTest.js;h=c8dada498742aa5f5efa5dab3d48f43018fac0f4;hb=ab2d10c6d62c4d2b834337e238cf2a618eec4412;hp=aa2932bf3c2fac8b630d398178c8afcf065a228b;hpb=7d0a84193f539d85267d1458aba35a42d7dbd03b;p=jquery.git diff --git a/src/jquery/coreTest.js b/src/jquery/coreTest.js index aa2932b..c8dada4 100644 --- a/src/jquery/coreTest.js +++ b/src/jquery/coreTest.js @@ -20,7 +20,7 @@ test("$()", function() { }); test("isFunction", function() { - expect(20); + expect(21); // Make sure that false values return false ok( !jQuery.isFunction(), "No Value" ); @@ -79,6 +79,15 @@ test("isFunction", function() { document.body.removeChild( input ); + var a = document.createElement("a"); + a.href = "some-function"; + document.body.appendChild( a ); + + // This serializes with the word 'function' in it + ok( !jQuery.isFunction(a), "Anchor Element" ); + + document.body.removeChild( a ); + // Recursive function calls have lengths and array-like properties function callme(callback){ function fn(response){