-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[QUESTION] How to write tests for components that use @nuxt/icon #197
Comments
Anyone? Am I the only one bothered by this warning ? |
i am also in trouble. The Icon component does not get rendered in my cypress component test. Did you found any way to get your problem solved? |
I just ditched the library :/ |
I will work on it and provide a template / guide to it later |
I did it in 5724416, it seems that directly following https://nuxt.com/docs/getting-started/testing would work, no specific steps required. |
Hello everyone!
I've stumbled upon an error while writing tests for my components that use nuxt/icon, specifically:
I've found in the docs of the testutils that you have to somehow wrap either
NuxtIcon
orMyComponent
with<Suspense/>
and it is also unclear how to importNuxtIcon
into the test file since we use<Icon/>
in the markup. Can you please show me how to write tests when using nuxt/icon ?I've created a reproduction setup, after installing all deps it will auto start the test and you will see the error.
https://stackblitz.com/edit/nuxt-vitest-iocqwn
Best regards
The text was updated successfully, but these errors were encountered: