diff --git a/test/editor/deserialize-test.js b/test/editor/deserialize-test.js
index be8fe8aeab..4184552559 100644
--- a/test/editor/deserialize-test.js
+++ b/test/editor/deserialize-test.js
@@ -149,7 +149,7 @@ describe('editor/deserialize', function() {
expect(parts[2]).toStrictEqual({type: "plain", text: "!"});
});
it('user pill with displayname containing backslash', function() {
- const html = "Hi Alice\!";
+ const html = "Hi Alice\\!";
const parts = normalize(parseEvent(htmlMessage(html), createPartCreator()));
expect(parts.length).toBe(3);
expect(parts[0]).toStrictEqual({type: "plain", text: "Hi "});
diff --git a/test/editor/serialize-test.js b/test/editor/serialize-test.js
index d5fb800600..a69e3598e3 100644
--- a/test/editor/serialize-test.js
+++ b/test/editor/serialize-test.js
@@ -43,13 +43,13 @@ describe('editor/serialize', function() {
const html = htmlSerializeIfNeeded(model, {});
expect(html).toBe("hello world");
});
- it('displaynames ending in a backslash work', function () {
+ it('displaynames ending in a backslash work', function() {
const pc = createPartCreator();
const model = new EditorModel([pc.userPill("Displayname\\", "@user:server")]);
const html = htmlSerializeIfNeeded(model, {});
- expect(html).toBe("Displayname\");
+ expect(html).toBe("Displayname\\");
});
- it('displaynames containing a closing square bracket work', function () {
+ it('displaynames containing a closing square bracket work', function() {
const pc = createPartCreator();
const model = new EditorModel([pc.userPill("Displayname]", "@user:server")]);
const html = htmlSerializeIfNeeded(model, {});