Skip to content

Commit e621f1a

Browse files
committed
fix tests
1 parent 61e5b43 commit e621f1a

File tree

1 file changed

+5
-1
lines changed
  • packages/svelte/tests/hydration

1 file changed

+5
-1
lines changed

packages/svelte/tests/hydration/test.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,11 @@ const { test, run } = suite<HydrationTest>(async (config, cwd) => {
132132
flushSync();
133133

134134
const normalize = (string: string) =>
135-
string.trim().replaceAll('\r\n', '\n').replaceAll('/>', '>');
135+
string
136+
.trim()
137+
.replaceAll('\r\n', '\n')
138+
.replaceAll('/>', '>')
139+
.replace(/<!--.+?-->/g, '');
136140

137141
const expected = read(`${cwd}/_expected.html`) ?? rendered.html;
138142
assert.equal(normalize(target.innerHTML), normalize(expected));

0 commit comments

Comments
 (0)