December 2016
Intermediate to advanced
841 pages
17h
English
We can test this application using the same set of tools that we used in the previous chapters of this book. As you already know, in order to run our unit test, we need to create a Gulp task like the following one:
gulp.task("run-unit-test", function(cb) {
karma.start({
configFile : "karma.conf.js",
singleRun: true
}, cb);
});We have used the Karma test runner, and we need to set its configuration using the karma.conf.js file. The karma.conf.js file is almost identical to the one that we used in Chapter 7, Application Testing, and will not be included here for the sake of brevity.
We also need a task to run some end-to-end tests:
gulp.task('run-e2e-test', function() { return gulp.src('') .pipe(nightwatch({ configFile: 'nightwatch.json' ...Read now
Unlock full access