X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=test%2Funit%2Fmanipulation.js;h=046d363ebb324a758272fca8084837e07e73d08f;hb=cb4880ee8353b5fc1a8a509cb0caf3a82818da0a;hp=52becfefb37a5a7281da1147df2362ab06476d4b;hpb=36a98b95c2f3f7617ddf51beec7515acf67d98ba;p=jquery.git diff --git a/test/unit/manipulation.js b/test/unit/manipulation.js index 52becfe..046d363 100644 --- a/test/unit/manipulation.js +++ b/test/unit/manipulation.js @@ -626,7 +626,7 @@ test("insertAfter(String|Element|Array<Element>|jQuery)", function() { }); var testReplaceWith = function(val) { - expect(16); + expect(17); jQuery('#yahoo').replaceWith(val( 'buga' )); ok( jQuery("#replace")[0], 'Replace element with string' ); ok( !jQuery("#yahoo")[0], 'Verify that original element is gone, after string' ); @@ -651,9 +651,13 @@ var testReplaceWith = function(val) { reset(); var tmp = jQuery("
").appendTo("body").click(function(){ ok(true, "Newly bound click run." ); }); var y = jQuery('#yahoo').click(function(){ ok(true, "Previously bound click run." ); }); + var child = y.append("test").find("b").click(function(){ ok(true, "Child bound click run." ); return false; }); + y.replaceWith( tmp ); + tmp.click(); y.click(); + child.click(); reset();