1
0
Fork 0

chore(core): Tests for path

This commit is contained in:
joostdecock 2022-07-23 20:21:16 +02:00
parent 470e4ccab6
commit c67c79af8f
4 changed files with 365 additions and 4 deletions

View file

@ -90,7 +90,7 @@ Path.prototype.curve_ = function (cp1, to) {
if (to instanceof Point !== true)
this.raise.warning('Called `Path.curve_(cp1, to)` but `to` is not a `Point` object')
if (cp1 instanceof Point !== true)
this.raise.warning('Called `Path.curve_(cp1, to)` but `cp2` is not a `Point` object')
this.raise.warning('Called `Path.curve_(cp1, to)` but `cp1` is not a `Point` object')
let cp2 = to.copy()
this.ops.push({ type: 'curve', cp1, cp2, to })
@ -599,7 +599,6 @@ Path.prototype.edge = function (side) {
return curveEdge(curve, side)
}
}
this.raise.error(`Unable to find \`Path.edge(side)\` for side ${side}`)
}
function edgeCurveAsBezier(op) {