Vue Test Utils v2.6.0

vuejs/test-utilsBreaking changes
Share
Summary
Vue Test Utils v2.6.0 introduces a breaking change where plain object and array props are no longer deeply reactive, requiring developers to use `reactive()` for in-place mutations. New features include `TeleportStub`, inferred emitted event names and payload types, and the ability to emit events via `VueWrapper.emit`. Numerous fixes enhance stability and compatibility, particularly with Vue 3.5 and functional components.

Breaking changes in v2.6.0

Plain object and array props are no longer made deeply reactive. Tests relying on in-place mutations must wrap values in reactive() before mounting, or pass a new value to setProps. Passing the same mutated object to setProps does not trigger a re-render. Already-reactive props stay reactive. See #2951 and the migration guidance.

Full release notes

⚠️ Breaking change

Plain object and array props are no longer made deeply reactive. Tests relying on in-place mutations must wrap values in reactive() before mounting, or pass a new value to setProps. Passing the same mutated object to setProps does not trigger a re-render. Already-reactive props stay reactive. See #2951 and the migration guidance.

What's Changed

New Contributors

Full Changelog: https://github.com/vuejs/test-utils/compare/v2.5.1...v2.6.0