diff --git a/crates/wysiwyg/src/dom/parser/parse.rs b/crates/wysiwyg/src/dom/parser/parse.rs
index c1dceb743..4c1fe5215 100644
--- a/crates/wysiwyg/src/dom/parser/parse.rs
+++ b/crates/wysiwyg/src/dom/parser/parse.rs
@@ -1404,7 +1404,9 @@ mod js {
#[wasm_bindgen_test]
fn br() {
- roundtrip("foo
bar");
+ let html = "foo
bar";
+ let dom = HtmlParser::default().parse::(html).unwrap();
+ assert_eq!(dom.to_string(), "foo
bar
");
}
#[wasm_bindgen_test]
diff --git a/platforms/web/lib/useWysiwyg.test.tsx b/platforms/web/lib/useWysiwyg.test.tsx
index 14b5251ba..0afc2b419 100644
--- a/platforms/web/lib/useWysiwyg.test.tsx
+++ b/platforms/web/lib/useWysiwyg.test.tsx
@@ -147,13 +147,17 @@ describe('useWysiwyg', () => {
});
test('Create wysiwyg with initial content', async () => {
- // When
+ // Given
const content = 'foo
bar';
+ const processedContent =
+ 'foo
bar
';
+
+ // When
render();
// Then
await waitFor(() =>
- expect(screen.getByRole('textbox')).toContainHTML(content),
+ expect(screen.getByRole('textbox')).toContainHTML(processedContent),
);
});