diff --git a/lib/liquid/variable_lookup.rb b/lib/liquid/variable_lookup.rb index 7a94616..6a58fe2 100644 --- a/lib/liquid/variable_lookup.rb +++ b/lib/liquid/variable_lookup.rb @@ -72,7 +72,7 @@ module Liquid protected def state - [@name, @lookup, @command_flags] + [@name, @lookups, @command_flags] end end end diff --git a/test/integration/context_test.rb b/test/integration/context_test.rb index d537aa2..2176fe0 100644 --- a/test/integration/context_test.rb +++ b/test/integration/context_test.rb @@ -23,12 +23,10 @@ class ContextTest < Minitest::Test end def test_has_key_will_not_add_an_error_for_missing_keys - Template.error_mode = :strict - - context = Context.new - - context.has_key?('unknown') - - assert_empty context.errors + with_error_mode :strict do + context = Context.new + context.has_key?('unknown') + assert_empty context.errors + end end end