mirror of
https://github.com/kemko/liquid.git
synced 2026-01-01 15:55:40 +03:00
Fix a leaky test that set Tempate.error_mode without resetting it (#1339)
This commit is contained in:
committed by
GitHub
parent
f23c2a83f2
commit
1d63d5db5f
@@ -257,9 +257,8 @@ class TemplateTest < Minitest::Test
|
||||
end
|
||||
|
||||
def test_nil_value_does_not_raise
|
||||
Liquid::Template.error_mode = :strict
|
||||
t = Template.parse("some{{x}}thing")
|
||||
result = t.render!({ 'x' => nil }, strict_variables: true)
|
||||
t = Template.parse("some{{x}}thing", error_mode: :strict)
|
||||
result = t.render!({ 'x' => nil }, strict_variables: true)
|
||||
|
||||
assert_equal(0, t.errors.count)
|
||||
assert_equal('something', result)
|
||||
|
||||
Reference in New Issue
Block a user