mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-04-20 14:11:52 +02:00
added test_hull_polyline2d
This commit is contained in:
parent
d2832e9dec
commit
96ea138de5
@ -2,6 +2,7 @@
|
||||
include <test_rounded_square.scad>;
|
||||
include <test_line2d.scad>;
|
||||
include <test_polyline2d.scad>;
|
||||
include <test_hull_polyline2d.scad>;
|
||||
|
||||
// 2D Shape
|
||||
include <test_shape_arc.scad>;
|
||||
|
26
test/test_hull_polyline2d.scad
Normal file
26
test/test_hull_polyline2d.scad
Normal file
@ -0,0 +1,26 @@
|
||||
include <unittest.scad>;
|
||||
|
||||
module test_hull_polyline2d() {
|
||||
echo("==== test_hull_polyline2d ====");
|
||||
|
||||
$fn = 4;
|
||||
points = [[1, 2], [-5, -4], [-5, 3], [5, 5]];
|
||||
line_width = 1;
|
||||
|
||||
include <hull_polyline2d.scad>;
|
||||
|
||||
module test_line_segment(index, point1, point2, radius) {
|
||||
assertEqualPoint(points[index - 1], point1);
|
||||
assertEqualPoint(points[index], point2);
|
||||
assertEqual(line_width, radius * 2);
|
||||
}
|
||||
|
||||
$fn = 4;
|
||||
|
||||
hull_polyline2d(
|
||||
points = [[1, 2], [-5, -4], [-5, 3], [5, 5]],
|
||||
width = 1
|
||||
);
|
||||
}
|
||||
|
||||
test_hull_polyline2d();
|
Loading…
x
Reference in New Issue
Block a user