aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorOleg <markelog@gmail.com>2013-01-08 02:08:47 +0000
committerDave Methvin <dave.methvin@gmail.com>2013-01-08 02:08:47 +0000
commit054daa20afc0e2c84e66f450b155d0253a62aedb (patch)
tree3616fd182c3c6098b7d7b217f9587eb8f5947722 /test
parent9434060722b7b935f61f8fb6c97a2a424255dc5d (diff)
downloadjquery-054daa20afc0e2c84e66f450b155d0253a62aedb.tar.gz
jquery-054daa20afc0e2c84e66f450b155d0253a62aedb.zip
Ref #8908. Update IE9 css clone fix. Close gh-1119.
Diffstat (limited to 'test')
-rw-r--r--test/unit/css.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/unit/css.js b/test/unit/css.js
index abc625933..8513913ee 100644
--- a/test/unit/css.js
+++ b/test/unit/css.js
@@ -883,7 +883,7 @@ test( "css opacity consistency across browsers (#12685)", function() {
equal( Math.round( el.css("opacity") * 100 ), 20, "remove opacity override" );
});
-asyncTest( "Clearing a Cloned Element's Style Shouldn't Clear the Original Element's Style (#8908)", 16, function() {
+asyncTest( "Clearing a Cloned Element's Style Shouldn't Clear the Original Element's Style (#8908)", 24, function() {
var baseUrl = document.location.href.replace( /([^\/]*)$/, "" ),
styles = [{
name: "backgroundAttachment",
@@ -921,7 +921,7 @@ asyncTest( "Clearing a Cloned Element's Style Shouldn't Clear the Original Eleme
expected: [ "auto auto" ]
}];
- jQuery.each( styles, function(index, style) {
+ jQuery.each(styles, function( index, style ) {
var $clone, $clonedChildren,
$source = jQuery( "#firstp" ),
source = $source[ 0 ],
@@ -932,6 +932,7 @@ asyncTest( "Clearing a Cloned Element's Style Shouldn't Clear the Original Eleme
if ( source.style[ style.name ] === undefined ) {
ok( true, style.name + ": style isn't supported and therefore not an issue" );
ok( true );
+
return true;
}
@@ -945,6 +946,8 @@ asyncTest( "Clearing a Cloned Element's Style Shouldn't Clear the Original Eleme
$clonedChildren.css( style.name, "" );
window.setTimeout(function() {
+ notEqual( $clone.css( style.name ), style.value[ 0 ], "Cloned css was changed" );
+
ok( jQuery.inArray( $source.css( style.name ) !== -1, style.value ),
"Clearing clone.css() doesn't affect source.css(): " + style.name +
"; result: " + $source.css( style.name ) +