The ability to reply to discussions is limited to PRO members. Want to join in the discussion? Click here to subscribe now.

Unit testing a React component using Jasmine and Webpack

Unit testing a React component using Jasmine and Webpack

4:04
An introduction on unit testing a ReactJS component using Webpack and Jasmine. Learn how to use Webpack to package and import dependencies plus take advantage of the babel-loader to write a simple Jasmine spec using the latest ES6 syntax.
Watch this lesson now
Avatar
egghead.io

An introduction on unit testing a ReactJS component using Webpack and Jasmine. Learn how to use Webpack to package and import dependencies plus take advantage of the babel-loader to write a simple Jasmine spec using the latest ES6 syntax.

Avatar
Kent C.

FYI, ES6 runs in implicit 'use strict'; mode, so transpilers (like babel) will add 'use strict'; to the output. :-)

Avatar
Simon

Cheers Kent, I've updated the code on Github to reflect this mate, thanks.

In reply to Kent C.
Avatar
dave

Is it possible to do a webpack , jasmine (or Jest) AND a test runner like karma ? This is useful but how would I incorporate tests into a build process , not just run tests ? Hope I make my self clear

In reply to Simon
HEY, QUICK QUESTION!
Joel's Head
Why are we asking?