README.md
64 lines
| 1 | # packaged angular-mocks |
| 2 | |
| 3 | This repo is for distribution on `npm` and `bower`. The source for this module is in the |
| 4 | [](https://github.com/angular/angular.js/tree/master/src/ngMockmain AngularJS repo](https://github.com/angular/angular.js/tree/master/src/ngMock](https://github.com/angular/angular.js/tree/master/src/ngMock). |
| 5 | Please file issues and pull requests against that repo. |
| 6 | |
| 7 | ## Install |
| 8 | |
| 9 | You can install this package either with `npm` or with `bower`. |
| 10 | |
| 11 | ### npm |
| 12 | |
| 13 | ```shell |
| 14 | npm install angular-mocks |
| 15 | ``` |
| 16 | |
| 17 | You can `require` ngMock modules: |
| 18 | |
| 19 | ```js |
| 20 | var angular = require('angular'); |
| 21 | angular.module('myMod', [ |
| 22 | require('angular-animate'), |
| 23 | require('angular-mocks/ngMock'), |
| 24 | require('angular-mocks/ngAnimateMock') |
| 25 | ]); |
| 26 | ``` |
| 27 | |
| 28 | ### bower |
| 29 | |
| 30 | ```shell |
| 31 | bower install angular-mocks |
| 32 | ``` |
| 33 | |
| 34 | The mocks are then available at `bower_components/angular-mocks/angular-mocks.js`. |
| 35 | |
| 36 | ## Documentation |
| 37 | |
| 38 | Documentation is available on the |
| 39 | [](https://docs.angularjs.org/guide/unit-testingAngularJS docs site](https://docs.angularjs.org/guide/unit-testing](https://docs.angularjs.org/guide/unit-testing). |
| 40 | |
| 41 | ## License |
| 42 | |
| 43 | The MIT License |
| 44 | |
| 45 | Copyright (c) 2010-2015 Google, Inc. http://angularjs.org |
| 46 | |
| 47 | Permission is hereby granted, free of charge, to any person obtaining a copy |
| 48 | of this software and associated documentation files (the "Software"), to deal |
| 49 | in the Software without restriction, including without limitation the rights |
| 50 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
| 51 | copies of the Software, and to permit persons to whom the Software is |
| 52 | furnished to do so, subject to the following conditions: |
| 53 | |
| 54 | The above copyright notice and this permission notice shall be included in |
| 55 | all copies or substantial portions of the Software. |
| 56 | |
| 57 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 58 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 59 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
| 60 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 61 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
| 62 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
| 63 | THE SOFTWARE. |
| 64 |