mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-08-09 23:05:04 -06:00
Ported ExtrusionPath to XS. Failing test for Surface
This commit is contained in:
parent
8c1e1cc3ea
commit
f612d4c64e
24 changed files with 501 additions and 143 deletions
22
xs/t/06_polygon.t
Normal file
22
xs/t/06_polygon.t
Normal file
|
@ -0,0 +1,22 @@
|
|||
#!/usr/bin/perl
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
use Slic3r::XS;
|
||||
use Test::More tests => 3;
|
||||
|
||||
my $square = [ # ccw
|
||||
[100, 100],
|
||||
[200, 100],
|
||||
[200, 200],
|
||||
[100, 200],
|
||||
];
|
||||
|
||||
my $polygon = Slic3r::Polygon::XS->new(@$square);
|
||||
is_deeply [ @$polygon ], [ @$square ], 'polygon roundtrip';
|
||||
|
||||
isa_ok $polygon->arrayref, 'Slic3r::Polygon', 'Perl polygon is blessed';
|
||||
isa_ok $polygon->[0], 'Slic3r::Point', 'Perl points are blessed';
|
||||
|
||||
__END__
|
Loading…
Add table
Add a link
Reference in a new issue