1
1
/**
2
- * @license AngularJS v1.6.8
2
+ * @license AngularJS v1.6.9-build.5526+sha.96dd35a
3
3
* (c) 2010-2017 Google, Inc. http://angularjs.org
4
4
* License: MIT
5
5
*/
@@ -803,7 +803,7 @@ angular.mock.TzDate.prototype = Date.prototype;
803
803
* You need to require the `ngAnimateMock` module in your test suite for instance `beforeEach(module('ngAnimateMock'))`
804
804
*/
805
805
angular . mock . animate = angular . module ( 'ngAnimateMock' , [ 'ng' ] )
806
- . info ( { angularVersion : '1.6.8 ' } )
806
+ . info ( { angularVersion : '1.6.9-build.5526+sha.96dd35a ' } )
807
807
808
808
. config ( [ '$provide' , function ( $provide ) {
809
809
@@ -969,7 +969,7 @@ angular.mock.animate = angular.module('ngAnimateMock', ['ng'])
969
969
*
970
970
* *NOTE*: This is not an injectable instance, just a globally available function.
971
971
*
972
- * Method for serializing common angular objects (scope, elements, etc..) into strings.
972
+ * Method for serializing common AngularJS objects (scope, elements, etc..) into strings.
973
973
* It is useful for logging objects to the console when debugging.
974
974
*
975
975
* @param {* } object - any object to turn into string.
@@ -1051,7 +1051,7 @@ angular.mock.dump = function(object) {
1051
1051
* This mock implementation can be used to respond with static or dynamic responses via the
1052
1052
* `expect` and `when` apis and their shortcuts (`expectGET`, `whenPOST`, etc).
1053
1053
*
1054
- * When an Angular application needs some data from a server, it calls the $http service, which
1054
+ * When an AngularJS application needs some data from a server, it calls the $http service, which
1055
1055
* sends the request to a real server using $httpBackend service. With dependency injection, it is
1056
1056
* easy to inject $httpBackend mock (which has the same API as $httpBackend) and use it to verify
1057
1057
* the requests and respond with some testing data without sending a request to a real server.
@@ -2097,13 +2097,13 @@ function MockXhr() {
2097
2097
var header = this . $$respHeaders [ name ] ;
2098
2098
if ( header ) return header ;
2099
2099
2100
- name = angular . lowercase ( name ) ;
2100
+ name = angular . $$ lowercase( name ) ;
2101
2101
header = this . $$respHeaders [ name ] ;
2102
2102
if ( header ) return header ;
2103
2103
2104
2104
header = undefined ;
2105
2105
angular . forEach ( this . $$respHeaders , function ( headerVal , headerName ) {
2106
- if ( ! header && angular . lowercase ( headerName ) === name ) header = headerVal ;
2106
+ if ( ! header && angular . $$ lowercase( headerName ) === name ) header = headerVal ;
2107
2107
} ) ;
2108
2108
return header ;
2109
2109
} ;
@@ -2120,7 +2120,7 @@ function MockXhr() {
2120
2120
this . abort = angular . noop ;
2121
2121
2122
2122
// This section simulates the events on a real XHR object (and the upload object)
2123
- // When we are testing $httpBackend (inside the angular project) we make partial use of this
2123
+ // When we are testing $httpBackend (inside the AngularJS project) we make partial use of this
2124
2124
// but store the events directly ourselves on `$$events`, instead of going through the `addEventListener`
2125
2125
this . $$events = { } ;
2126
2126
this . addEventListener = function ( name , listener ) {
@@ -2231,11 +2231,6 @@ angular.mock.$RootElementProvider = function() {
2231
2231
* A decorator for {@link ng.$controller} with additional `bindings` parameter, useful when testing
2232
2232
* controllers of directives that use {@link $compile#-bindtocontroller- `bindToController`}.
2233
2233
*
2234
- * Depending on the value of
2235
- * {@link ng.$compileProvider#preAssignBindingsEnabled `preAssignBindingsEnabled()`}, the properties
2236
- * will be bound before or after invoking the constructor.
2237
- *
2238
- *
2239
2234
* ## Example
2240
2235
*
2241
2236
* ```js
@@ -2281,8 +2276,6 @@ angular.mock.$RootElementProvider = function() {
2281
2276
*
2282
2277
* * check if a controller with given name is registered via `$controllerProvider`
2283
2278
* * check if evaluating the string on the current scope returns a constructor
2284
- * * if $controllerProvider#allowGlobals, check `window[constructor]` on the global
2285
- * `window` object (deprecated, not recommended)
2286
2279
*
2287
2280
* The string can use the `controller as property` syntax, where the controller instance is published
2288
2281
* as the specified property on the `scope`; the `scope` must be injected into `locals` param for this
@@ -2293,22 +2286,13 @@ angular.mock.$RootElementProvider = function() {
2293
2286
* the `bindToController` feature and simplify certain kinds of tests.
2294
2287
* @return {Object } Instance of given controller.
2295
2288
*/
2296
- function createControllerDecorator ( compileProvider ) {
2289
+ function createControllerDecorator ( ) {
2297
2290
angular . mock . $ControllerDecorator = [ '$delegate' , function ( $delegate ) {
2298
2291
return function ( expression , locals , later , ident ) {
2299
2292
if ( later && typeof later === 'object' ) {
2300
- var preAssignBindingsEnabled = compileProvider . preAssignBindingsEnabled ( ) ;
2301
-
2302
2293
var instantiate = $delegate ( expression , locals , true , ident ) ;
2303
- if ( preAssignBindingsEnabled ) {
2304
- angular . extend ( instantiate . instance , later ) ;
2305
- }
2306
-
2307
2294
var instance = instantiate ( ) ;
2308
- if ( ! preAssignBindingsEnabled || instance !== instantiate . instance ) {
2309
- angular . extend ( instance , later ) ;
2310
- }
2311
-
2295
+ angular . extend ( instance , later ) ;
2312
2296
return instance ;
2313
2297
}
2314
2298
return $delegate ( expression , locals , later , ident ) ;
@@ -2426,7 +2410,7 @@ angular.module('ngMock', ['ng']).provider({
2426
2410
$provide . decorator ( '$rootScope' , angular . mock . $RootScopeDecorator ) ;
2427
2411
$provide . decorator ( '$controller' , createControllerDecorator ( $compileProvider ) ) ;
2428
2412
$provide . decorator ( '$httpBackend' , angular . mock . $httpBackendDecorator ) ;
2429
- } ] ) . info ( { angularVersion : '1.6.8 ' } ) ;
2413
+ } ] ) . info ( { angularVersion : '1.6.9-build.5526+sha.96dd35a ' } ) ;
2430
2414
2431
2415
/**
2432
2416
* @ngdoc module
@@ -2435,13 +2419,13 @@ angular.module('ngMock', ['ng']).provider({
2435
2419
* @packageName angular-mocks
2436
2420
* @description
2437
2421
*
2438
- * The `ngMockE2E` is an angular module which contains mocks suitable for end-to-end testing.
2422
+ * The `ngMockE2E` is an AngularJS module which contains mocks suitable for end-to-end testing.
2439
2423
* Currently there is only one mock present in this module -
2440
2424
* the {@link ngMockE2E.$httpBackend e2e $httpBackend} mock.
2441
2425
*/
2442
2426
angular . module ( 'ngMockE2E' , [ 'ng' ] ) . config ( [ '$provide' , function ( $provide ) {
2443
2427
$provide . decorator ( '$httpBackend' , angular . mock . e2e . $httpBackendDecorator ) ;
2444
- } ] ) . info ( { angularVersion : '1.6.8 ' } ) ;
2428
+ } ] ) . info ( { angularVersion : '1.6.9-build.5526+sha.96dd35a ' } ) ;
2445
2429
2446
2430
/**
2447
2431
* @ngdoc service
@@ -3368,30 +3352,11 @@ angular.mock.$RootScopeDecorator = ['$delegate', function($delegate) {
3368
3352
3369
3353
if ( ! evnt ) return ;
3370
3354
3371
- var originalPreventDefault = evnt . preventDefault ,
3372
- appWindow = element . ownerDocument . defaultView ,
3373
- fakeProcessDefault = true ,
3374
- finalProcessDefault ,
3375
- angular = appWindow . angular || { } ;
3376
-
3377
- // igor: temporary fix for https://bugzilla.mozilla.org/show_bug.cgi?id=684208
3378
- angular [ 'ff-684208-preventDefault' ] = false ;
3379
- evnt . preventDefault = function ( ) {
3380
- fakeProcessDefault = false ;
3381
- return originalPreventDefault . apply ( evnt , arguments ) ;
3382
- } ;
3383
-
3384
3355
if ( ! eventData . bubbles || supportsEventBubblingInDetachedTree ( ) || isAttachedToDocument ( element ) ) {
3385
- element . dispatchEvent ( evnt ) ;
3356
+ return element . dispatchEvent ( evnt ) ;
3386
3357
} else {
3387
3358
triggerForPath ( element , evnt ) ;
3388
3359
}
3389
-
3390
- finalProcessDefault = ! ( angular [ 'ff-684208-preventDefault' ] || ! fakeProcessDefault ) ;
3391
-
3392
- delete angular [ 'ff-684208-preventDefault' ] ;
3393
-
3394
- return finalProcessDefault ;
3395
3360
} ;
3396
3361
3397
3362
function supportsTouchEvents ( ) {
0 commit comments