mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 11:35:04 +01:00
Fix test
This commit is contained in:
parent
7f91653208
commit
f9f7f6cc6f
@ -501,13 +501,12 @@ export async function tests() {
|
|||||||
},
|
},
|
||||||
"Reply fallback is always stripped": assert => {
|
"Reply fallback is always stripped": assert => {
|
||||||
const input = 'Hello, <em><mx-reply>World</mx-reply></em>!';
|
const input = 'Hello, <em><mx-reply>World</mx-reply></em>!';
|
||||||
const strippedInput = 'Hello, <em></em>!';
|
|
||||||
const output = [
|
const output = [
|
||||||
new TextPart('Hello, '),
|
new TextPart('Hello, '),
|
||||||
new FormatPart("em", []),
|
new FormatPart("em", []),
|
||||||
new TextPart('!'),
|
new TextPart('!'),
|
||||||
];
|
];
|
||||||
assert.deepEqual(parseHTMLBody(platform, null, input), new MessageBody(strippedInput, output));
|
assert.deepEqual(parseHTMLBody(platform, null, input), new MessageBody(input, output));
|
||||||
}
|
}
|
||||||
/* Doesnt work: HTML library doesn't handle <pre><code> properly.
|
/* Doesnt work: HTML library doesn't handle <pre><code> properly.
|
||||||
"Text with code block": assert => {
|
"Text with code block": assert => {
|
||||||
|
Loading…
Reference in New Issue
Block a user