fix(ivy): enable packages/core/test/render3 test for AoT (#26863)
PR Close #26863
This commit is contained in:

committed by
Kara Erickson

parent
516af6c531
commit
c13f46c7c5
@ -6,7 +6,7 @@
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {Component, ElementRef, InjectFlags, Injectable, InjectionToken, InjectorType, Provider, ViewEncapsulation, createInjector, defineInjectable, defineInjector, inject} from '../../src/core';
|
||||
import {Component as _Component, ElementRef, InjectFlags, Injectable as _Injectable, InjectionToken, InjectorType, Provider, ViewEncapsulation, createInjector, defineInjectable, defineInjector, inject} from '../../src/core';
|
||||
import {forwardRef} from '../../src/di/forward_ref';
|
||||
import {getRenderedText} from '../../src/render3/component';
|
||||
|
||||
@ -18,6 +18,15 @@ import {NgIf} from './common_with_def';
|
||||
import {getRendererFactory2} from './imported_renderer2';
|
||||
import {ComponentFixture, containerEl, createComponent, renderComponent, renderToHtml, requestAnimationFrame, toHtml} from './render_util';
|
||||
|
||||
const Component: typeof _Component = function(...args: any[]): any {
|
||||
// In test we use @Component for documentation only so it's safe to mock out the implementation.
|
||||
return () => undefined;
|
||||
} as any;
|
||||
const Injectable: typeof _Injectable = function(...args: any[]): any {
|
||||
// In test we use @Injectable for documentation only so it's safe to mock out the implementation.
|
||||
return () => undefined;
|
||||
} as any;
|
||||
|
||||
describe('component', () => {
|
||||
class CounterComponent {
|
||||
count = 0;
|
||||
|
Reference in New Issue
Block a user