2015-08-26 14:41:41 -04:00
|
|
|
import {
|
|
|
|
ChangeDetector,
|
|
|
|
ChangeDetectorRef,
|
|
|
|
ProtoChangeDetector,
|
|
|
|
DynamicChangeDetector
|
|
|
|
} from 'angular2/src/core/change_detection/change_detection';
|
|
|
|
|
2015-12-02 13:35:51 -05:00
|
|
|
import {Renderer} from 'angular2/src/core/render/api';
|
2015-10-02 10:37:23 -04:00
|
|
|
import {DirectiveResolver} from 'angular2/src/core/linker/directive_resolver';
|
|
|
|
|
2015-12-02 13:35:51 -05:00
|
|
|
import {AppView, AppProtoView, HostViewFactory} from 'angular2/src/core/linker/view';
|
2015-10-02 10:37:23 -04:00
|
|
|
import {ElementRef} from 'angular2/src/core/linker/element_ref';
|
2015-12-02 13:35:51 -05:00
|
|
|
import {AppViewManager_} from 'angular2/src/core/linker/view_manager';
|
2015-11-19 18:09:34 -05:00
|
|
|
import {DomAdapter} from 'angular2/src/platform/dom/dom_adapter';
|
2015-08-26 14:41:41 -04:00
|
|
|
|
2015-10-13 03:29:13 -04:00
|
|
|
import {SpyObject, proxy} from 'angular2/testing_internal';
|
2015-08-26 14:41:41 -04:00
|
|
|
|
|
|
|
export class SpyDependencyProvider extends SpyObject {}
|
|
|
|
|
|
|
|
export class SpyChangeDetector extends SpyObject {
|
|
|
|
constructor() { super(DynamicChangeDetector); }
|
|
|
|
}
|
|
|
|
|
2015-09-30 18:28:26 -04:00
|
|
|
export class SpyChangeDispatcher extends SpyObject {}
|
|
|
|
|
2015-08-26 14:41:41 -04:00
|
|
|
export class SpyIterableDifferFactory extends SpyObject {}
|
|
|
|
|
|
|
|
export class SpyDirectiveResolver extends SpyObject {
|
|
|
|
constructor() { super(DirectiveResolver); }
|
|
|
|
}
|
|
|
|
|
|
|
|
export class SpyView extends SpyObject {
|
|
|
|
constructor() { super(AppView); }
|
|
|
|
}
|
|
|
|
|
2015-12-02 13:35:51 -05:00
|
|
|
export class SpyProtoView extends SpyObject {
|
|
|
|
constructor() { super(AppProtoView); }
|
|
|
|
}
|
|
|
|
|
|
|
|
export class SpyHostViewFactory extends SpyObject {
|
|
|
|
constructor() { super(HostViewFactory); }
|
|
|
|
}
|
|
|
|
|
2015-08-26 14:41:41 -04:00
|
|
|
export class SpyElementRef extends SpyObject {
|
|
|
|
constructor() { super(ElementRef); }
|
|
|
|
}
|
|
|
|
|
|
|
|
export class SpyAppViewManager extends SpyObject {
|
2015-12-02 13:35:51 -05:00
|
|
|
constructor() { super(AppViewManager_); }
|
2015-08-26 14:41:41 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
export class SpyRenderer extends SpyObject {
|
2015-10-06 22:39:44 -04:00
|
|
|
constructor() {
|
|
|
|
// Note: Renderer is an abstract class,
|
|
|
|
// so we can't generates spy functions automatically
|
|
|
|
// by inspecting the prototype...
|
|
|
|
super(Renderer);
|
2015-12-02 13:35:51 -05:00
|
|
|
this.spy('renderComponent');
|
|
|
|
this.spy('selectRootElement');
|
|
|
|
this.spy('createElement');
|
|
|
|
this.spy('createViewRoot');
|
|
|
|
this.spy('createTemplateAnchor');
|
|
|
|
this.spy('createText');
|
|
|
|
this.spy('projectNodes');
|
|
|
|
this.spy('attachViewAfter');
|
|
|
|
this.spy('detachView');
|
2015-10-06 22:39:44 -04:00
|
|
|
this.spy('destroyView');
|
2015-12-02 13:35:51 -05:00
|
|
|
this.spy('listen');
|
|
|
|
this.spy('listenGlobal');
|
|
|
|
this.spy('setElementProperty');
|
|
|
|
this.spy('setElementAttribute');
|
|
|
|
this.spy('setBindingDebugInfo');
|
2016-01-14 00:35:21 -05:00
|
|
|
this.spy('setElementDebugInfo');
|
2015-12-02 13:35:51 -05:00
|
|
|
this.spy('setElementClass');
|
|
|
|
this.spy('setElementStyle');
|
|
|
|
this.spy('invokeElementMethod');
|
|
|
|
this.spy('setText');
|
2015-10-06 22:39:44 -04:00
|
|
|
}
|
2015-08-26 14:41:41 -04:00
|
|
|
}
|
|
|
|
|
2015-12-02 13:35:51 -05:00
|
|
|
export class SpyRootRenderer extends SpyObject {
|
|
|
|
constructor() {
|
|
|
|
// Note: RootRenderer is an abstract class,
|
|
|
|
// so we can't generates spy functions automatically
|
|
|
|
// by inspecting the prototype...
|
|
|
|
super(SpyRootRenderer);
|
|
|
|
this.spy('renderComponent');
|
|
|
|
}
|
2015-08-26 14:41:41 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
export class SpyDomAdapter extends SpyObject {
|
|
|
|
constructor() { super(DomAdapter); }
|
2015-09-02 18:07:31 -04:00
|
|
|
}
|