Bones/node_modules/zone.js/dist/jasmine-patch.js
SOUTHERNCO\x2mjbyrn 7efe7605b8 Template Upload
2017-05-17 13:45:25 -04:00

78 lines
2.8 KiB
JavaScript

/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ return installedModules[moduleId].exports;
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ exports: {},
/******/ id: moduleId,
/******/ loaded: false
/******/ };
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/ // Flag the module as loaded
/******/ module.loaded = true;
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/ // Load entry module and return exports
/******/ return __webpack_require__(0);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ function(module, exports) {
/* WEBPACK VAR INJECTION */(function(global) {'use strict';
// Patch jasmine's it and fit functions so that the `done` wrapCallback always resets the zone
// to the jasmine zone, which should be the root zone. (angular/zone.js#91)
if (!Zone) {
throw new Error('zone.js does not seem to be installed');
}
var SET_TIMEOUT = '__zone_symbol__setTimeout';
var _global = typeof window == 'undefined' ? global : window;
// When you have in async test (test with `done` argument) jasmine will
// execute the next test synchronously in the done handler. This makes sense
// for most tests, but now with zones. With zones running next test
// synchronously means that the current zone does not get cleared. This
// results in a chain of nested zones, which makes it hard to reason about
// it. We override the `clearStack` method which forces jasmine to always
// drain the stack before next test gets executed.
jasmine.QueueRunner = (function (SuperQueueRunner) {
// Subclass the `QueueRunner` and override the `clearStack` method.
function alwaysClearStack(fn) {
_global[SET_TIMEOUT](fn, 0);
}
function QueueRunner(options) {
options.clearStack = alwaysClearStack;
SuperQueueRunner.call(this, options);
}
QueueRunner.prototype = SuperQueueRunner.prototype;
return QueueRunner;
})(jasmine.QueueRunner);
/* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
/***/ }
/******/ ]);