mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-18 02:10:41 -07:00
Use render! in tests to make debugging test failures easier.
This commit is contained in:
+2
-2
@@ -26,13 +26,13 @@ module Test
|
||||
include Liquid
|
||||
|
||||
def assert_template_result(expected, template, assigns = {}, message = nil)
|
||||
assert_equal expected, Template.parse(template).render(assigns)
|
||||
assert_equal expected, Template.parse(template).render!(assigns)
|
||||
end
|
||||
|
||||
def assert_template_result_matches(expected, template, assigns = {}, message = nil)
|
||||
return assert_template_result(expected, template, assigns, message) unless expected.is_a? Regexp
|
||||
|
||||
assert_match expected, Template.parse(template).render(assigns)
|
||||
assert_match expected, Template.parse(template).render!(assigns)
|
||||
end
|
||||
|
||||
def assert_match_syntax_error(match, template, registers = {})
|
||||
|
||||
Reference in New Issue
Block a user