chore(core): Tests for path
This commit is contained in:
parent
470e4ccab6
commit
c67c79af8f
4 changed files with 365 additions and 4 deletions
|
@ -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) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue