aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorjeresig <jeresig@gmail.com>2011-02-23 13:18:44 -0500
committerjeresig <jeresig@gmail.com>2011-02-23 13:18:44 -0500
commit292acd97a226ec15af2adc069d02973d59c6bc59 (patch)
tree1226999ac7d6c8a549105ace2930478cacdb9006 /test/unit
parent3663836b0180f3a73d96ec234d5d7010e5652a4b (diff)
downloadjquery-292acd97a226ec15af2adc069d02973d59c6bc59.tar.gz
jquery-292acd97a226ec15af2adc069d02973d59c6bc59.zip
Make a new jQuery.support.noCloneChecked - splitting apart the previous feature detect relating to clone in IE, fixes the last remaining issue with IE 9 RC. Fixes #8365.
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/manipulation.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/unit/manipulation.js b/test/unit/manipulation.js
index 1313783e0..34425ed3a 100644
--- a/test/unit/manipulation.js
+++ b/test/unit/manipulation.js
@@ -402,7 +402,8 @@ test("append(Function) with incoming value", function() {
});
test("append the same fragment with events (Bug #6997, 5566)", function () {
- expect(2 + (document.fireEvent ? 1 : 0));
+ var doExtra = !jQuery.support.noCloneEvent && document.fireEvent;
+ expect(2 + (doExtra ? 1 : 0));
stop(1000);
var element;
@@ -410,7 +411,7 @@ test("append the same fragment with events (Bug #6997, 5566)", function () {
// This patch modified the way that cloning occurs in IE; we need to make sure that
// native event handlers on the original object don't get disturbed when they are
// modified on the clone
- if (!jQuery.support.noCloneEvent && document.fireEvent) {
+ if ( doExtra ) {
element = jQuery("div:first").click(function () {
ok(true, "Event exists on original after being unbound on clone");
jQuery(this).unbind('click');
@@ -1015,7 +1016,7 @@ test("clone(form element) (Bug #3879, #6655)", function() {
equals( clone.is(":checked"), element.is(":checked"), "Checked input cloned correctly" );
equals( clone[0].defaultValue, "foo", "Checked input defaultValue cloned correctly" );
- equals( clone[0].defaultChecked, !jQuery.support.noCloneEvent, "Checked input defaultChecked cloned correctly" );
+ equals( clone[0].defaultChecked, !jQuery.support.noCloneChecked, "Checked input defaultChecked cloned correctly" );
element = jQuery("<input type='text' value='foo'>");
clone = element.clone();