Localize errors in Liquid

This commit is contained in:
Simon Eskildsen
2013-08-30 12:31:57 -04:00
parent 29cdabc30e
commit 072c12dc47
13 changed files with 55 additions and 22 deletions
+6
View File
@@ -18,4 +18,10 @@ class AssignTest < Test::Unit::TestCase
'{% assign foo = values | split: "," %}.{{ foo[1] }}.',
'values' => "foo,bar,baz")
end
def test_assign_syntax_error
assert_match_syntax_error(/assign/,
'{% assign foo not values %}.',
'values' => "foo,bar,baz")
end
end # AssignTest
+1
View File
@@ -146,6 +146,7 @@ class TemplateTest < Test::Unit::TestCase
def test_sets_default_localization_in_document
t = Template.new
t.parse('')
assert_instance_of I18n, t.root.options[:locale]
end