mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-03 19:45:44 -05:00
parent
ce7d584c05
commit
3db6e103c2
1 changed files with 15 additions and 1 deletions
|
@ -87,4 +87,18 @@ test('getDirectedAngle(point)', function() {
|
||||||
|
|
||||||
var angle = new Point(10, -10).getDirectedAngle(new Point(1, 0));
|
var angle = new Point(10, -10).getDirectedAngle(new Point(1, 0));
|
||||||
equals(angle, 45);
|
equals(angle, 45);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('equals()', function() {
|
||||||
|
equals(function() {
|
||||||
|
return new Point(10, 10).equals([10, 10]);
|
||||||
|
}, true);
|
||||||
|
|
||||||
|
equals(function() {
|
||||||
|
return new Point(0, 0).equals({});
|
||||||
|
}, false);
|
||||||
|
|
||||||
|
equals(function() {
|
||||||
|
return new Point(0, 0).equals(null);
|
||||||
|
}, false);
|
||||||
|
});
|
||||||
|
|
Loading…
Reference in a new issue