Project

General

Profile

Defect #44692 » 0001-Fix-ApplicationHelperTest-test_wiki_textarea_stimulu.patch

Marius BĂLTEANU, 2026-10-28 23:19

View differences:

test/helpers/application_helper_test.rb
assert_equal '', result
end
def test_wiki_textarea_stimulus_attributes
with_settings :text_formatting => 'textile' do
expected = {
controller: "list-autofill selection-indent table-paste",
action: "beforeinput->list-autofill#handleBeforeInput keydown.tab->selection-indent#run " \
"keydown.shift+tab->selection-indent#run paste->table-paste#handlePaste",
list_autofill_text_formatting_param: "textile",
selection_indent_text_formatting_param: "textile",
table_paste_text_formatting_param: "textile"
}
assert_equal expected, wiki_textarea_stimulus_attributes
end
end
def test_wiki_textarea_stimulus_attributes_with_blank_text_formatting
with_settings :text_formatting => '' do
assert_equal({}, wiki_textarea_stimulus_attributes)
end
end
private
def wiki_links_with_special_characters
......
:class => "wiki-page new"),
}
end
def test_wiki_textarea_stimulus_attributes
with_settings :text_formatting => 'textile' do
expected = {
controller: "list-autofill table-paste",
action: "beforeinput->list-autofill#handleBeforeInput paste->table-paste#handlePaste",
list_autofill_text_formatting_param: "textile",
table_paste_text_formatting_param: "textile"
}
assert_equal expected, wiki_textarea_stimulus_attributes
end
end
def test_wiki_textarea_stimulus_attributes_with_blank_text_formatting
with_settings :text_formatting => '' do
assert_equal({}, wiki_textarea_stimulus_attributes)
end
end
end
    (1-1/1)