mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-03 19:45:44 -05:00
Use #appendTop() instead of the remove #appendChild() in tests.
This commit is contained in:
parent
515dbbb151
commit
4be0e55dc5
1 changed files with 3 additions and 3 deletions
|
@ -42,10 +42,10 @@ test('clone()', function() {
|
||||||
}, true);
|
}, true);
|
||||||
});
|
});
|
||||||
|
|
||||||
test('appendChild(item)', function() {
|
test('appendTop(item)', function() {
|
||||||
var proj = paper.project;
|
var proj = paper.project;
|
||||||
var path = new Path();
|
var path = new Path();
|
||||||
proj.activeLayer.appendChild(path);
|
proj.activeLayer.appendTop(path);
|
||||||
equals(function() {
|
equals(function() {
|
||||||
return proj.activeLayer.children.length;
|
return proj.activeLayer.children.length;
|
||||||
}, 1);
|
}, 1);
|
||||||
|
@ -55,7 +55,7 @@ test('item.parent / item.isChild / item.isParent', function() {
|
||||||
var proj = paper.project;
|
var proj = paper.project;
|
||||||
var secondDoc = new Project();
|
var secondDoc = new Project();
|
||||||
var path = new Path();
|
var path = new Path();
|
||||||
proj.activeLayer.appendChild(path);
|
proj.activeLayer.appendTop(path);
|
||||||
equals(function() {
|
equals(function() {
|
||||||
return proj.activeLayer.children.indexOf(path) != -1;
|
return proj.activeLayer.children.indexOf(path) != -1;
|
||||||
}, true);
|
}, true);
|
||||||
|
|
Loading…
Reference in a new issue