diff --git a/packages/runtime-core/__tests__/hydration.spec.ts b/packages/runtime-core/__tests__/hydration.spec.ts index c5dbe539..76e8b153 100644 --- a/packages/runtime-core/__tests__/hydration.spec.ts +++ b/packages/runtime-core/__tests__/hydration.spec.ts @@ -366,6 +366,35 @@ describe('SSR hydration', () => { ) }) + test('Teleport (as component root)', () => { + const teleportContainer = document.createElement('div') + teleportContainer.id = 'teleport4' + teleportContainer.innerHTML = `hello` + document.body.appendChild(teleportContainer) + + const wrapper = { + render() { + return h(Teleport, { to: '#teleport4' }, ['hello']) + } + } + + const { vnode, container } = mountWithHydration( + '