Skip to content

Commit

Permalink
initial test for preComputing
Browse files Browse the repository at this point in the history
  • Loading branch information
RStankov committed Feb 17, 2010
1 parent 4a487cc commit 8ad626e
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion test/unit/layout_test.js
Expand Up @@ -14,7 +14,17 @@ function isDisplayed(element) {
new Test.Unit.Runner({
setup: function() {
},

'test preCompute argument of layout': function() {
var preComputedLayout = $('box1').getLayout(true),
normalLayout = $('box1').getLayout();

// restore normal get method from Hash object
preComputedLayout.get = Hash.prototype.get;

Element.Layout.PROPERTIES.each(function(key) {
this.assertEqual(normalLayout.get(key), preComputedLayout.get(key), key);
}, this);
},
'test layout on absolutely-positioned elements': function() {
var layout = $('box1').getLayout();

Expand Down

0 comments on commit 8ad626e

Please sign in to comment.