Skip to content

Reword preference of Vue Testing Library over Vue Test Utils #330

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

Merged
merged 2 commits into from
Jul 24, 2020

Conversation

afontcu
Copy link
Member

@afontcu afontcu commented Jul 23, 2020

This PR aims to clarify the statement where the official docs recommend Vue Testing Library over Vue Test Utils (the official library).

When developing the new version of VTU, we wanted to frame it as an “enabling” library. VTU 2 is both a complete library to test out components, and also a baseline to build other tools – We even developed a plugin system. This means that VTU is still a valid choice, and that there's no need to rewrite any codebase from VTU to Vue Testing Library.

During conversarions, we agreed that Vue Testing Library had a terser, useful API and that we should recommend it to newcomers.

Closes #326

@@ -86,7 +86,7 @@ Its guiding principle is that the more tests resemble the way software is used,

#### Vue Test Utils

Vue Test Utils is the low-level component testing library that was written to provide users access to Vue specific APIs. While it is officially maintained, we recommend most users use Vue Testing Library, which is an abstraction over Vue Test Utils.
Vue Test Utils is the official low-level component testing library that was written to provide users access to Vue specific APIs. If you are starting testing Vue applications, we would recommend using Vue Testing Library, which is an abstraction over Vue Test Utils.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be "If you are new to testing" or "If you are starting a new application"?

I like the testing library philosophy more, but I like the VTU API more 😱 that said I don't mind which library is used, as long as people are testing their apps 👍

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed! thanks. copy&paste went wrong 😇

@NataliaTepluhina
Copy link
Member

I believe we have a coon consensus here 😅 Thanks @afontcu for the contribution!

@NataliaTepluhina NataliaTepluhina merged commit 058386a into vuejs:master Jul 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Vue Testing Library Recommendation
5 participants