Unit Testing in JavaScript: Should.js & Must.js


Overview/Description
Expected Duration
Lesson Objectives
Course Number
Expertise Level



Overview/Description

This 12-video course explores unit testing on software development paradigms, the support testing provided by JS (JavaScript) and the assertion libraries available in JS. Learners will examine how Unit.js offers extended APIs (application program interface) to communicate between various software components. First, you will learn to use sign-on, which is invaluable in constructing spice, stubs, and mocks in JS. You will learn how to use the Mocha testing framework. This course examines the assertion libraries Should.js and Must.js, which extend the base object.prototype in Javascript, to write assertions for every object by using a very intuitive and easy-to-read style. You will learn to use this assertion libraries to test code by using a chained assertion style. This course examines the fluent style Should.js uses for assertions, and the several helper methods available to chain multiple assertions together. Finally, you will learn to write unit tests to test numbers, strings, truthy and falsy values, objects, arrays, and promises in Javascript.



Expected Duration (hours)
1.2

Lesson Objectives

Unit Testing in JavaScript: Should.js & Must.js

  • discover the key concepts covered in this course
  • recall the different styles that can be used with the Should.js API
  • describe how different data types can be tested using Should.js
  • execute assertions to check for values that evaluate to true and false using Should.js
  • perform pattern matching and substring checks using Should.js
  • evaluate numeric values using Should.js
  • examine objects and properties using Should.js
  • evaluate functions that return promises
  • recall the different styles that can be used with the Must.js API
  • run basic assertions using Must.js
  • use assertions to test different data types with Must.js
  • summarize the key concepts covered in this course
  • Course Number:
    it_aputjsdj_02_enus

    Expertise Level
    Intermediate