aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/manipulation.js
diff options
context:
space:
mode:
authorOleg <markelog@gmail.com>2013-01-07 18:38:21 +0400
committerDave Methvin <dave.methvin@gmail.com>2013-01-08 02:41:15 +0000
commitc9bf5c5e905ec8c4d29c61f8ddf04d8a40d8e04e (patch)
tree0855fae1b990f242a24004c3675d183072f2c0c4 /test/unit/manipulation.js
parent054daa20afc0e2c84e66f450b155d0253a62aedb (diff)
downloadjquery-c9bf5c5e905ec8c4d29c61f8ddf04d8a40d8e04e.tar.gz
jquery-c9bf5c5e905ec8c4d29c61f8ddf04d8a40d8e04e.zip
Bring back jQuery.buildFragment and remove jQuery.clean
Diffstat (limited to 'test/unit/manipulation.js')
-rw-r--r--test/unit/manipulation.js21
1 files changed, 2 insertions, 19 deletions
diff --git a/test/unit/manipulation.js b/test/unit/manipulation.js
index 25ca9cd5b..5d229e575 100644
--- a/test/unit/manipulation.js
+++ b/test/unit/manipulation.js
@@ -463,12 +463,13 @@ var testAppend = function( valueObj ) {
jQuery.each( "thead tbody tfoot colgroup caption tr th td".split(" "), function( i, name ) {
$table.append( valueObj( "<" + name + "/>" ) );
equal( $table.find( name ).length, 1, "Append " + name );
- ok( jQuery.clean( ["<" + name + "/>"] ).length, name + " wrapped correctly" );
+ ok( jQuery.parseHTML( "<" + name + "/>" ).length, name + " wrapped correctly" );
});
jQuery("#table colgroup").append( valueObj("<col/>") );
equal( jQuery("#table colgroup col").length, 1, "Append col" );
+
jQuery("#form")
.append( valueObj("<select id='appendSelect1'></select>") )
.append( valueObj("<select id='appendSelect2'><option>Test</option></select>") );
@@ -641,24 +642,6 @@ test( "append HTML5 sectioning elements (Bug #6485)", function() {
equal( aside.length, 1, "HTML5 elements do not collapse their children" );
});
-test( "jQuery.clean, #12392", function() {
-
- expect( 6 );
-
- var elems = jQuery.clean( [ "<div>test div</div>", "<p>test p</p>" ] );
-
- ok( elems[ 0 ].parentNode == null || elems[ 0 ].parentNode.nodeType === 11, "parentNode should be documentFragment or null" );
- ok( elems[ 1 ].parentNode == null || elems[ 1 ].parentNode.nodeType === 11, "parentNode should be documentFragment or null" );
-
- equal( elems[ 0 ].innerHTML, "test div", "Content should be preserved" );
- equal( elems[ 1 ].innerHTML, "test p", "Content should be preserved" );
-
- equal( jQuery.clean([ "<span><span>" ]).length, 1, "Incorrect html-strings should not break anything" );
-
- elems = jQuery.clean([ "<td><td>" ]);
- ok( elems[ 1 ].parentNode == null || elems[ 1 ].parentNode.nodeType === 11, "parentNode should be documentFragment or null" );
-});
-
if ( jQuery.css ) {
test( "HTML5 Elements inherit styles from style rules (Bug #10501)", function() {