X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=test%2Funit%2Fcss.js;h=9c262af97c193fd217d42b59c60d7f6b4712cc53;hb=ee845c49758eeb5236d9e4520b7921e12d5f29b9;hp=ff17149d275b66dfcf5eb485961b3e7001d056d5;hpb=9ede46b00423491fe5852b16ab0ed448e1f0f055;p=jquery.git diff --git a/test/unit/css.js b/test/unit/css.js index ff17149..9c262af 100644 --- a/test/unit/css.js +++ b/test/unit/css.js @@ -1,7 +1,7 @@ module("css"); test("css(String|Hash)", function() { - expect(34); + expect(41); equals( jQuery('#main').css("display"), 'block', 'Check for css property "display"'); @@ -11,6 +11,24 @@ test("css(String|Hash)", function() { jQuery('#nothiddendiv').css({display: 'block'}); ok( jQuery('#nothiddendiv').is(':visible'), 'Modified CSS display: Assert element is visible'); + var div = jQuery( "
" ); + + equals( div.css("width"), "", "Width on disconnected node." ); + equals( div.css("height"), "", "Height on disconnected node." ); + + div.css({ width: 4, height: 4 }); + + equals( div.css("width"), "4px", "Width on disconnected node." ); + equals( div.css("height"), "4px", "Height on disconnected node." ); + + var div2 = jQuery( "