mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-21 12:15:21 +00:00
Add unit test to check that nested config options work
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
use Test::More tests => 1;
|
||||
use Test::More tests => 2;
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
@@ -10,6 +10,7 @@ BEGIN {
|
||||
use Slic3r;
|
||||
use Slic3r::Test;
|
||||
|
||||
{
|
||||
my $config = Slic3r::Config->new_from_defaults;
|
||||
|
||||
my $test = sub {
|
||||
@@ -37,5 +38,15 @@ my $test = sub {
|
||||
|
||||
$config->set('layer_gcode', '_MY_CUSTOM_GCODE_');
|
||||
ok $test->(), "custom layer G-code is applied after Z move and before other moves";
|
||||
}
|
||||
|
||||
#==========================================================
|
||||
|
||||
{
|
||||
my $config = Slic3r::Config->new_from_defaults;
|
||||
is $config->replace_options('[temperature_[foo]]', { foo => '0' }),
|
||||
200,
|
||||
"nested config options";
|
||||
}
|
||||
|
||||
__END__
|
||||
|
||||
Reference in New Issue
Block a user