Skip to content

Commit

Permalink
fix(asserts): fixed issue with asserts in latest ava
Browse files Browse the repository at this point in the history
  • Loading branch information
kaosat-dev committed Apr 27, 2017
1 parent 5482f5d commit 1210f66
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test/helpers/asserts.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ function comparePolygons(a, b){
let start = a.vertices[0];
let index = b.vertices.findIndex(v => {
if (!v) {return false;}

return v._x === start._x && v._y === start._y && v._z === start._z;
});
if (index === -1) {
Expand All @@ -38,7 +38,7 @@ function assertSameGeometry(t, a, b, failMessage) {
if (!containsCSG(a, b) || !containsCSG(b, a)) {
failMessage = failMessage == undefined ? 'CSG do not have the same geometry' : failMessage;
t.fail(failMessage);
}
}else{ t.pass()}
}

// a contains b if b polygons are also found in a
Expand All @@ -59,4 +59,4 @@ function containsCSG(a, b){
module.exports = {
assertSameGeometry: assertSameGeometry,
comparePolygons: comparePolygons
};
};

0 comments on commit 1210f66

Please sign in to comment.