Skip to content
Browse files

Update test/unit/manipulation.js

  • Loading branch information...
1 parent a221422 commit fedc198117a8d96c03718931d7cf6f0107b8543f @danielchatfield danielchatfield committed Jul 24, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 test/unit/manipulation.js
View
8 test/unit/manipulation.js
@@ -1897,8 +1897,8 @@ test("html() - script exceptions bubble (#11743)", function() {
});
test("checked state is cloned with clone()", function(){
- var div = jQuery('div').html( '<input type="checkbox" checked="checked" />' );
- var input = jQuery( div ).find('input')[0];
- input.checked = false;
- ok( !jQuery(input).clone()[0].checked, 'Checked state correctly cloned' );
+ var elem = jQuery.parseHTML('<input type="checkbox" checked="checked"/>')[0];
+ elem.checked = false;
+ var result = !jQuery(elem).clone().attr('id','clone')[0].checked;
+ ok( result, 'Checked state correctly cloned' );
});

0 comments on commit fedc198

Please sign in to comment.
Something went wrong with that request. Please try again.