You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-08-07 21:23:00 +03:00
Merge branch 'develop' into sort-imports
Signed-off-by: Aaron Raimist <aaron@raim.ist>
This commit is contained in:
1171
test/components/views/messages/MPollBody-test.tsx
Normal file
1171
test/components/views/messages/MPollBody-test.tsx
Normal file
File diff suppressed because it is too large
Load Diff
@@ -282,6 +282,30 @@ describe("<TextualBody />", () => {
|
||||
'!ZxbRYPQXDXKGmDnJNg:example.com</a></span> with vias</span>',
|
||||
);
|
||||
});
|
||||
|
||||
it('renders formatted body without html corretly', () => {
|
||||
const ev = mkEvent({
|
||||
type: "m.room.message",
|
||||
room: "room_id",
|
||||
user: "sender",
|
||||
content: {
|
||||
body: "escaped \\*markdown\\*",
|
||||
msgtype: "m.text",
|
||||
format: "org.matrix.custom.html",
|
||||
formatted_body: "escaped *markdown*",
|
||||
},
|
||||
event: true,
|
||||
});
|
||||
|
||||
const wrapper = mount(<TextualBody mxEvent={ev} />);
|
||||
|
||||
const content = wrapper.find(".mx_EventTile_body");
|
||||
expect(content.html()).toBe(
|
||||
'<span class="mx_EventTile_body" dir="auto">' +
|
||||
'escaped *markdown*' +
|
||||
'</span>',
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
it("renders url previews correctly", () => {
|
||||
|
2468
test/components/views/messages/__snapshots__/MPollBody-test.tsx.snap
Normal file
2468
test/components/views/messages/__snapshots__/MPollBody-test.tsx.snap
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user