Add failing test where cloning a linked size throws an error.

This commit is contained in:
Jonathan Puckey 2011-06-21 18:42:53 +02:00
parent bda60f1f90
commit 115d12f6ce

View file

@ -440,4 +440,18 @@ test('Changing item#position.x', function() {
var path = new Path.Circle(new Point(50, 50), 50);
path.position.x += 5;
equals(path.position.toString(), '{ x: 55, y: 50 }', 'path.position.x += 5');
});
test('Cloning a linked size', function() {
var path = new Path([40, 75], [140, 75]);
var error = null;
try {
var cloneSize = path.bounds.size.clone();
} catch (e) {
error = e;
}
var description = 'Cloning a linked size should not throw an error';
if (error)
description += ': ' + error;
equals(error == null, true, description);
});