Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/prusa3d/PrusaSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlessandro Ranellucci <aar@cpan.org>2013-07-28 15:39:15 +0400
committerAlessandro Ranellucci <aar@cpan.org>2013-07-28 15:39:15 +0400
commit91cade7e8f0b1b4c160bde4df77c1c785923632b (patch)
tree31eb65a440d2bd2c68c4aca9c465f7faac53b6b1 /t/shells.t
parent691c45d57fd1e8e0f898e0afde4528ea2760c64b (diff)
Make sure there are no gaps in spiral vase. Includes regression test. #1251
Diffstat (limited to 't/shells.t')
-rw-r--r--t/shells.t25
1 files changed, 24 insertions, 1 deletions
diff --git a/t/shells.t b/t/shells.t
index d84adb3e1..0da0099ea 100644
--- a/t/shells.t
+++ b/t/shells.t
@@ -1,4 +1,4 @@
-use Test::More tests => 4;
+use Test::More tests => 5;
use strict;
use warnings;
@@ -99,4 +99,27 @@ use Slic3r::Test;
"shells are not propagated across perimeters of the neighbor layer";
}
+{
+ my $config = Slic3r::Config->new_from_defaults;
+ $config->set('spiral_vase', 1);
+ $config->set('bottom_solid_layers', 0);
+ $config->set('skirts', 0);
+
+ # TODO: this needs to be tested with a model with sloping edges, where starting
+ # points of each layer are not aligned - in that case we would test that no
+ # travel moves are left to move to the new starting point - in a cube, end
+ # points coincide with next layer starting points (provided there's no clipping)
+ my $print = Slic3r::Test::init_print('20mm_cube', config => $config);
+ my $travel_moves_after_first_extrusion = 0;
+ my $started_extruding = 0;
+ Slic3r::GCode::Reader->new(gcode => Slic3r::Test::gcode($print))->parse(sub {
+ my ($self, $cmd, $args, $info) = @_;
+
+ $started_extruding = 1 if $info->{extruding};
+ $travel_moves_after_first_extrusion++
+ if $info->{travel} && $started_extruding && !exists $args->{Z};
+ });
+ is $travel_moves_after_first_extrusion, 0, "no gaps in spiral vase";
+}
+
__END__