added stage transition resize manual test

This commit is contained in:
Eric Rowell
2013-04-07 00:15:15 -07:00
parent 9fd5df4d79
commit 8f22bb1938
2 changed files with 30 additions and 0 deletions

View File

@@ -1388,5 +1388,34 @@ Test.Modules.DRAG_AND_DROP = {
stage.add(layer); stage.add(layer);
},
'*transition stage width': function(containerId) {
var stage = new Kinetic.Stage({
container: containerId,
width: 578,
height: 200
});
var layer = new Kinetic.Layer();
layer.canvas.element.style.backgroundColor = 'blue';
var rect = new Kinetic.Rect({
x: 10,
y: 10,
width: 100,
height: 50,
fill: 'red'
});
layer.add(rect);
stage.add(layer);
stage.transitionTo({
width: 300,
duration: 2
});
} }
}; };

View File

@@ -6,6 +6,7 @@ Test.Modules.STAGE = {
height: 200 height: 200
}); });
}, },
'instantiate stage with dom element': function(containerId) { 'instantiate stage with dom element': function(containerId) {
var containerDom = document.getElementById(containerId); var containerDom = document.getElementById(containerId);
var stage = new Kinetic.Stage({ var stage = new Kinetic.Stage({