Top 5 Testing and Mocking AngularJS Modules

Here is what we think are the Top 5 Testing and Mocking AngularJS Modules at the moment. There are many forms of testing with Angular apps such as integration/e2e testing, unit testing, performance testing etc… how do you keep on top of it all? Well AngularJS was designed with Testing in mind – dependency injection allows us to inject “mock” versions of services, driective and other ng omponents to simulate scenarios and output test results. There is also concerns about cross browser testing such as does it render correctly? or does it function correctly?

To help you get started you could take a look at Testing an ng Directive or Introduction to Testing in AngularJS. I would suggest trying out one of the testing modules below and have a play around with running different types of tests. From there you’ll be able to start writing your own tests as you code new modules, services, directives and other ng components.

This post was last updated on: 25/6/2015. For an updated list see more Testing and Mocking AngularJS Modules

1. Angular Kickstart by Alessandro Arnodo

angular-kickstart
angular-kickstart

Speed up your AngularJS development with a complete and scalable gulpjs based build system that scaffolds the project for you. Just focus on your app, angular-kickstart will take care of the rest.

GitHub Website + Demo

2. Angularjs Quizzler by Thomas Burleson

angularjs-Quizzler
angularjs-Quizzler

The AngularJS Challenge: Create an online Quiz builder & testing application.

GitHub Website + Demo

3. Bower Angular Mocks by Angular

bower-angular-mocks
bower-angular-mocks

angular-mocks.js bower repo.

GitHub

4. Angularjs Typescript e2e by Anchann

angularjs-typescript-e2e
angularjs-typescript-e2e

Sample AngularJS app in TypeScript with working httpBackend-mocked E2E tests

GitHub

5. Angular Socket.io Mock by Bryan Tong

angular-socket.io-mock
angular-socket.io-mock

Mock Socket.io bindings for AngularJS, useful for testing as a drop in replacement for https://github.com/btford/angular-socket-io which allows testing against a fake server.

GitHub

Thank you for reading and if you would like to you can submit your Testing and Mocking AngularJS Modules or leave a comment below.

Post tags: Testing and Mocking, a/b testing, mocks, test, mock, testing, date mocking, unit testing.

Sam is a web developer, online entrepreneur and investor. In his spare time he enjoys coding, playing chess and love to share what he learns.

4 thoughts on “Top 5 Testing and Mocking AngularJS Modules

Leave a Reply

Your email address will not be published. Required fields are marked *