Correctly handle exception messages in macros (#42326).

Patch by Holger Just (user:hjust).


git-svn-id: https://svn.redmine.org/redmine/trunk@23519 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Marius Balteanu
2025-03-06 21:42:27 +00:00
parent e29067913f
commit 40b6dce2de
2 changed files with 3 additions and 3 deletions

View File

@@ -140,12 +140,12 @@ class Redmine::WikiFormatting::MacrosTest < Redmine::HelperTest
def test_macro_exception_should_be_displayed
Redmine::WikiFormatting::Macros.macro :exception do |obj, args|
raise "My message"
raise "My exception's message"
end
text = "{{exception}}"
assert_include(
'<div class="flash error">Error executing the <strong>exception</strong> macro (My message)</div>',
'<div class="flash error">Error executing the <strong>exception</strong> macro (My exception&#39;s message)</div>',
textilizable(text)
)
end