mirror of
https://github.com/discourse/discourse.git
synced 2025-05-31 17:37:15 +08:00
FIX: supports escape sequence in chat (#29659)
Writing `\*test\*` will now correctly cook `*test*`, and not `<em>test</em>`.
This commit is contained in:
@ -133,6 +133,12 @@ describe Chat::Message do
|
||||
expect(cooked).to eq("<p>—</p>")
|
||||
end
|
||||
|
||||
it "supports escape sequence" do
|
||||
cooked = described_class.cook('\*test\*')
|
||||
|
||||
expect(cooked).to eq("<p>*test*</p>")
|
||||
end
|
||||
|
||||
it "supports backticks rule" do
|
||||
cooked = described_class.cook("`test`")
|
||||
|
||||
|
Reference in New Issue
Block a user