Skip to content

grusingh/vue-unit-testing-applied

Repository files navigation

VueJs Unit Testing Applied

This cook book is a collection of recipes applying unit testing to real world VueJs applications.

Prerequisites

Unit test libraries

Vue-test-utils is the core libary that enables unit tesing of Vue applications. Please follow the best practises documented on Vue-test-utils website.

Vue-test-utils-helper library provides helper functions for mocking components, Vuex and Vue Router.

Quick refresher on unit testing

In computer programming, unit testing is a software testing method by which individual units of source code, sets of one or more computer program modules together with associated control data, usage procedures, and operating procedures, are tested to determine whether they are fit for use. wikipedia

In VueJs world the units that we test are:

  • Components (including Views)
  • Directives
  • Functions (filters, services, utilities)
  • Store modules

Table of contents

About

A guide that offers examples on how to approach various uses cases when unit testing a VueJs application.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published