X-Git-Url: http://git.asbjorn.it/?a=blobdiff_plain;f=test%2Funit%2Fmanipulation.js;h=7b4f4d15909ae15f2cf7e280dced211ed03df4f2;hb=91028794d5029365eca0c3d40cfdae016403cbe6;hp=e1d3dbf6add31f9a8ea8d869edad6bfefe1491b5;hpb=43fbe3b33aeaa73c151ddb59632c85bc7f8a87b9;p=jquery.git diff --git a/test/unit/manipulation.js b/test/unit/manipulation.js index e1d3dbf..7b4f4d1 100644 --- a/test/unit/manipulation.js +++ b/test/unit/manipulation.js @@ -899,7 +899,7 @@ var testHtml = function(valueObj) { equals( div.children().children().length, 1, "Make sure that a grandchild exists." ); var space = jQuery("
").html(valueObj(" "))[0].innerHTML; - ok( /^\s$|^ $/.test( space ), "Make sure entities are passed through correctly." ); + ok( /^\xA0$|^ $/.test( space ), "Make sure entities are passed through correctly." ); equals( jQuery("
").html(valueObj("&"))[0].innerHTML, "&", "Make sure entities are passed through correctly." ); jQuery("#main").html(valueObj("")); @@ -955,6 +955,17 @@ test("html(String)", function() { test("html(Function)", function() { testHtml(functionReturningObj); + + expect(33); + + QUnit.reset(); + + jQuery("#main").html(function(){ + return jQuery(this).text(); + }); + + ok( !/ 0, "Make sure text exists." ); }); test("html(Function) with incoming value", function() {