From eb00d57bac2af3fe1de837a321ed91f8741644f3 Mon Sep 17 00:00:00 2001 From: Thorsten Eckel Date: Wed, 20 Dec 2017 15:42:50 +0100 Subject: [PATCH] Improved output to show real content of variable via inspect instead of calling .to_s on it. --- lib/sequencer/state.rb | 4 ++-- lib/sequencer/unit/import/common/sub_sequence/mixin/base.rb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/sequencer/state.rb b/lib/sequencer/state.rb index 8498744fb..a3987a75d 100644 --- a/lib/sequencer/state.rb +++ b/lib/sequencer/state.rb @@ -13,7 +13,7 @@ class Sequencer @values = {} initialize_attributes(sequence.units) - initialize_parameters(parameters.with_indifferent_access) + initialize_parameters(parameters) initialize_expectations(expecting || sequence.expecting) end @@ -195,7 +195,7 @@ class Sequencer end def unprovideable_setter(attribute, value) - message = "Unprovideable attribute '#{attribute}' set with value (#{value.class.name}): '#{value}'" + message = "Unprovideable attribute '#{attribute}' set with value (#{value.class.name}): #{value.inspect}" logger.error(message) raise message end diff --git a/lib/sequencer/unit/import/common/sub_sequence/mixin/base.rb b/lib/sequencer/unit/import/common/sub_sequence/mixin/base.rb index 33baa5250..656ffb765 100644 --- a/lib/sequencer/unit/import/common/sub_sequence/mixin/base.rb +++ b/lib/sequencer/unit/import/common/sub_sequence/mixin/base.rb @@ -24,7 +24,7 @@ class Sequencer end def sequence_resource(resource) - sequence_parameter = default_params.dup + sequence_parameter = default_parameter.dup sequence_parameter[:resource] = resource sequence_parameter = yield(sequence_parameter) if block_given? @@ -32,7 +32,7 @@ class Sequencer sequence_parameter[:resource] = sequence_parameter[:resource].to_h.with_indifferent_access ::Sequencer.process(sequence_name, - parameters: default_params.merge(sequence_parameter)) + parameters: sequence_parameter) end def sequence_resources(resources, &block)