From the course: Vue.js: Testing and Debugging

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Mounting components using render

Mounting components using render

From the course: Vue.js: Testing and Debugging

Mounting components using render

- [Instructor] Now that we have a good understanding of testing JavaScript data types, it's time to start testing Vue JS components. Vue JS component needs to be mounted into a DOM environment for it to be used. Because of this, we need tools that will help simulate a DOM environment in our test environment and mount our Vue JS components on it. To follow along with this video, you need the 03_01b branch to follow the project. So make sure you're on the 03_01b branch. Jest is a very extendable framework. And in this video we'll be installing a couple of packages that are compatible with Jest for testing Vue JS components. The first set of packages we would install is the 'vue test utils' package and the 'vue jest' package. The 'vue test utils' library is the official unit testing utility library for Vue JS. It provides all the low-level APIs for mounting and working with Vue JS components. The 'vue jest' library on the…

Contents