zurg
Test Utils: wrapper.find Always Returns Empty DOMWrapper
I'm converting an app for Nuxt 2 to Nuxt 3. I've updated the unit test config to use Nuxt test utils and the Nuxt environment but wrapper.find only ever returns an empty DOMWrapper i.e. does not find anything, even though the wrapper.html looks correct
vitest.config.ts
spec file
Test failure
I've tested with mount and mountSuspended, if I console.log(wrapper.html()) I can see the the element it's search for is in the dom, thanks for any help
12 replies