mirror of
https://github.com/Shopify/liquid.git
synced 2026-10-03 09:05:13 -07:00
Add assert_syntax_error convenience method
This commit is contained in:
@@ -56,6 +56,10 @@ module Minitest
|
|||||||
assert_match(match, exception.message)
|
assert_match(match, exception.message)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def assert_syntax_error(template, error_mode: nil)
|
||||||
|
assert_match_syntax_error("", template, error_mode: error_mode)
|
||||||
|
end
|
||||||
|
|
||||||
def assert_usage_increment(name, times: 1)
|
def assert_usage_increment(name, times: 1)
|
||||||
old_method = Liquid::Usage.method(:increment)
|
old_method = Liquid::Usage.method(:increment)
|
||||||
calls = 0
|
calls = 0
|
||||||
|
|||||||
Reference in New Issue
Block a user