UNPKG

ng-zorro-antd

Version:

An enterprise-class UI components based on Ant Design and Angular

60 lines (58 loc) 6.91 kB
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/common"),require("@angular/core/testing"),require("@angular/platform-browser/animations")):"function"==typeof define&&define.amd?define("ng-zorro-antd/core/testing",["exports","@angular/core","@angular/common","@angular/core/testing","@angular/platform-browser/animations"],t):t(((e="undefined"!=typeof globalThis?globalThis:e||self)["ng-zorro-antd"]=e["ng-zorro-antd"]||{},e["ng-zorro-antd"].core=e["ng-zorro-antd"].core||{},e["ng-zorro-antd"].core.testing={}),e.ng.core,e.ng.common,e.ng.core.testing,e.ng.platformBrowser.animations)}(this,(function(e,t,n,r,o){"use strict"; /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */function i(e,t,n,r){void 0===t&&(t=0),void 0===n&&(n=0),void 0===r&&(r=0);var o=document.createEvent("MouseEvent");return o.initMouseEvent(e,!0,!1,window,0,t,n,t,n,!1,!1,!1,!1,r,null),Object.defineProperty(o,"buttons",{get:function(){return 1}}),o}function u(e,t,n){void 0===t&&(t=0),void 0===n&&(n=0);var r=new UIEvent(e,{detail:0,view:window}),o={pageX:t,pageY:n,clientX:t,clientY:n};return Object.defineProperties(r,{touches:{value:[o]},targetTouches:{value:[o]},changedTouches:{value:[o]}}),r}function a(e,t,n,r,o,i,u){var a=document.createEvent("KeyboardEvent"),c=a.preventDefault;return a.initKeyEvent?a.initKeyEvent(e,!0,!0,window,0,0,0,0,0,t):a.initKeyboardEvent(e,!0,!0,window,0,r,0,"",!1),Object.defineProperties(a,{keyCode:{get:function(){return t}},key:{get:function(){return r}},target:{get:function(){return n}},ctrlKey:{get:function(){return o}},metaKey:{get:function(){return i}},shiftKey:{get:function(){return u}}}),a.preventDefault=function(){return Object.defineProperty(a,"defaultPrevented",{get:function(){return!0},configurable:!0}),c.apply(this,arguments)},a}function c(e,t,n){void 0===t&&(t=!0),void 0===n&&(n=!0);var r=document.createEvent("Event");return r.initEvent(e,t,n),r} /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */function f(e,t){return e.dispatchEvent(t),t}function l(e,t,n){return f(e,c(t,n))} /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */ var d=function(){function e(){}return e.prototype.getViewportRect=function(){return{left:0,top:0,width:1014,height:686,bottom:686,right:1014}},e.prototype.getViewportSize=function(){return{width:1014,height:686}},e.prototype.getViewportScrollPosition=function(){return{top:0,left:0}},e}(),s=function(e,t){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)}; /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */Object.create;function p(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),u=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)u.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return u}function v(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(p(arguments[t]));return e}Object.create;var g=function(e){function n(){var n=e.call(this,{enableLongStackTrace:!1})||this;return n.onStable=new t.EventEmitter(!1),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}s(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}(n,e),n.prototype.run=function(e){return e()},n.prototype.runOutsideAngular=function(e){return e()},n.prototype.simulateZoneExit=function(){this.onStable.emit(null)},n}(t.NgZone);g.decorators=[{type:t.Injectable}],g.ctorParameters=function(){return[]}, /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */ e.FakeViewportRuler=d,e.MockNgZone=g,e.createFakeEvent=c,e.createKeyboardEvent=a,e.createMouseEvent=i,e.createTouchEvent=u,e.dispatchEvent=f,e.dispatchFakeEvent=l,e.dispatchKeyboardEvent=function(e,t,n,r){return f(e,a(t,n,r))},e.dispatchMouseEvent=function(e,t,n,r,o){return void 0===n&&(n=0),void 0===r&&(r=0),void 0===o&&(o=i(t,n,r)),f(e,o)},e.dispatchTouchEvent=function(e,t,n,r){return void 0===n&&(n=0),void 0===r&&(r=0),f(e,u(t,n,r))} /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */,e.typeInElement=function(e,t){t.focus(),t.value=e,l(t,"input")} /** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */,e.wrappedErrorMessage=function(e){var t=e.message.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&");return new RegExp(t)},e.ɵcreateComponentBed=function(e,i){void 0===i&&(i={providers:[],declarations:[],imports:[]});var u=i.imports,a=i.declarations,c=i.providers,f={imports:v([o.NoopAnimationsModule,n.CommonModule],u||[]),declarations:v([e],a||[]),schemas:[t.NO_ERRORS_SCHEMA],providers:c||[]},l=r.TestBed.configureTestingModule(f),d=r.TestBed.createComponent(e);return d.detectChanges(),{bed:l,fixture:d,nativeElement:d.nativeElement,debugElement:d.debugElement,component:d.componentInstance}},Object.defineProperty(e,"__esModule",{value:!0})})); //# sourceMappingURL=ng-zorro-antd-core-testing.umd.min.js.map