diff --git a/packages/compiler-cli/integrationtest/bazel/injectable_def/app/test/app_spec.ts b/packages/compiler-cli/integrationtest/bazel/injectable_def/app/test/app_spec.ts index b7d7bf0fb7..ecbbd7fbfc 100644 --- a/packages/compiler-cli/integrationtest/bazel/injectable_def/app/test/app_spec.ts +++ b/packages/compiler-cli/integrationtest/bazel/injectable_def/app/test/app_spec.ts @@ -168,21 +168,20 @@ describe('ngInjectableDef Bazel Integration', () => { expect(TestBed.get(INJECTOR).get('foo')).toEqual('bar'); }); - fixmeIvy('FW-854: NodeInjector does not know how to get itself (INJECTOR)') - .it('Component injector understands requests for INJECTABLE', () => { - @Component({ - selector: 'test-cmp', - template: 'test', - providers: [{provide: 'foo', useValue: 'bar'}], - }) - class TestCmp { - } + it('Component injector understands requests for INJECTABLE', () => { + @Component({ + selector: 'test-cmp', + template: 'test', + providers: [{provide: 'foo', useValue: 'bar'}], + }) + class TestCmp { + } - TestBed.configureTestingModule({ - declarations: [TestCmp], - }); + TestBed.configureTestingModule({ + declarations: [TestCmp], + }); - const fixture = TestBed.createComponent(TestCmp); - expect(fixture.componentRef.injector.get(INJECTOR).get('foo')).toEqual('bar'); - }); + const fixture = TestBed.createComponent(TestCmp); + expect(fixture.componentRef.injector.get(INJECTOR).get('foo')).toEqual('bar'); + }); }); diff --git a/packages/router/test/integration.spec.ts b/packages/router/test/integration.spec.ts index 5edb0bc5be..7cc31061d5 100644 --- a/packages/router/test/integration.spec.ts +++ b/packages/router/test/integration.spec.ts @@ -12,7 +12,6 @@ import {ChangeDetectionStrategy, Component, Injectable, NgModule, NgModuleFactor import {ComponentFixture, TestBed, fakeAsync, inject, tick} from '@angular/core/testing'; import {By} from '@angular/platform-browser/src/dom/debug/by'; import {expect} from '@angular/platform-browser/testing/src/matchers'; -import {fixmeIvy} from '@angular/private/testing'; import {ActivatedRoute, ActivatedRouteSnapshot, ActivationEnd, ActivationStart, CanActivate, CanDeactivate, ChildActivationEnd, ChildActivationStart, DetachedRouteHandle, Event, GuardsCheckEnd, GuardsCheckStart, Navigation, NavigationCancel, NavigationEnd, NavigationError, NavigationStart, PRIMARY_OUTLET, ParamMap, Params, PreloadAllModules, PreloadingStrategy, Resolve, ResolveEnd, ResolveStart, RouteConfigLoadEnd, RouteConfigLoadStart, RouteReuseStrategy, Router, RouterEvent, RouterModule, RouterPreloader, RouterStateSnapshot, RoutesRecognized, RunGuardsAndResolvers, UrlHandlingStrategy, UrlSegmentGroup, UrlSerializer, UrlTree} from '@angular/router'; import {Observable, Observer, Subscription, of } from 'rxjs'; import {filter, first, map, tap} from 'rxjs/operators'; diff --git a/packages/upgrade/test/dynamic/upgrade_spec.ts b/packages/upgrade/test/dynamic/upgrade_spec.ts index 8277f6e0b8..11160bd777 100644 --- a/packages/upgrade/test/dynamic/upgrade_spec.ts +++ b/packages/upgrade/test/dynamic/upgrade_spec.ts @@ -169,53 +169,50 @@ withEachNg1Version(() => { }); describe('scope/component change-detection', () => { - fixmeIvy( - 'FW-918: Create API and mental model to work with Host Element; and ChangeDetections') - .it('should interleave scope and component expressions', async(() => { - const adapter: UpgradeAdapter = new UpgradeAdapter(forwardRef(() => Ng2Module)); - const ng1Module = angular.module('ng1', []); - const log: string[] = []; - const l = (value: string) => { - log.push(value); - return value + ';'; - }; + it('should interleave scope and component expressions', async(() => { + const adapter: UpgradeAdapter = new UpgradeAdapter(forwardRef(() => Ng2Module)); + const ng1Module = angular.module('ng1', []); + const log: string[] = []; + const l = (value: string) => { + log.push(value); + return value + ';'; + }; - ng1Module.directive('ng1a', () => ({template: '{{ l(\'ng1a\') }}'})); - ng1Module.directive('ng1b', () => ({template: '{{ l(\'ng1b\') }}'})); - ng1Module.run(($rootScope: any) => { - $rootScope.l = l; - $rootScope.reset = () => log.length = 0; - }); + ng1Module.directive('ng1a', () => ({template: '{{ l(\'ng1a\') }}'})); + ng1Module.directive('ng1b', () => ({template: '{{ l(\'ng1b\') }}'})); + ng1Module.run(($rootScope: any) => { + $rootScope.l = l; + $rootScope.reset = () => log.length = 0; + }); - @Component({ - selector: 'ng2', - template: `{{l('2A')}}{{l('2B')}}{{l('2C')}}` - }) - class Ng2 { - l: any; - constructor() { this.l = l; } - } + @Component({ + selector: 'ng2', + template: `{{l('2A')}}{{l('2B')}}{{l('2C')}}` + }) + class Ng2 { + l: any; + constructor() { this.l = l; } + } - @NgModule({ - declarations: [ - adapter.upgradeNg1Component('ng1a'), adapter.upgradeNg1Component('ng1b'), Ng2 - ], - imports: [BrowserModule], - }) - class Ng2Module { - } + @NgModule({ + declarations: + [adapter.upgradeNg1Component('ng1a'), adapter.upgradeNg1Component('ng1b'), Ng2], + imports: [BrowserModule], + }) + class Ng2Module { + } - ng1Module.directive('ng2', adapter.downgradeNg2Component(Ng2)); + ng1Module.directive('ng2', adapter.downgradeNg2Component(Ng2)); - const element = - html('
{{reset(); l(\'1A\');}}{{l(\'1B\')}}{{l(\'1C\')}}
'); - adapter.bootstrap(element, ['ng1']).ready((ref) => { - expect(document.body.textContent).toEqual('1A;2A;ng1a;2B;ng1b;2C;1C;'); - // https://github.com/angular/angular.js/issues/12983 - expect(log).toEqual(['1A', '1C', '2A', '2B', '2C', 'ng1a', 'ng1b']); - ref.dispose(); - }); - })); + const element = + html('
{{reset(); l(\'1A\');}}{{l(\'1B\')}}{{l(\'1C\')}}
'); + adapter.bootstrap(element, ['ng1']).ready((ref) => { + expect(document.body.textContent).toEqual('1A;2A;ng1a;2B;ng1b;2C;1C;'); + // https://github.com/angular/angular.js/issues/12983 + expect(log).toEqual(['1A', '1C', '2A', '2B', '2C', 'ng1a', 'ng1b']); + ref.dispose(); + }); + })); it('should propagate changes to a downgraded component inside the ngZone', async(() => { diff --git a/packages/upgrade/test/static/integration/change_detection_spec.ts b/packages/upgrade/test/static/integration/change_detection_spec.ts index b74c08c4ef..a46feca1a8 100644 --- a/packages/upgrade/test/static/integration/change_detection_spec.ts +++ b/packages/upgrade/test/static/integration/change_detection_spec.ts @@ -21,61 +21,60 @@ withEachNg1Version(() => { beforeEach(() => destroyPlatform()); afterEach(() => destroyPlatform()); - fixmeIvy('FW-918: Create API and mental model to work with Host Element; and ChangeDetections') - .it('should interleave scope and component expressions', async(() => { - const log: string[] = []; - const l = (value: string) => { - log.push(value); - return value + ';'; - }; + it('should interleave scope and component expressions', async(() => { + const log: string[] = []; + const l = (value: string) => { + log.push(value); + return value + ';'; + }; - @Directive({selector: 'ng1a'}) - class Ng1aComponent extends UpgradeComponent { - constructor(elementRef: ElementRef, injector: Injector) { - super('ng1a', elementRef, injector); - } - } + @Directive({selector: 'ng1a'}) + class Ng1aComponent extends UpgradeComponent { + constructor(elementRef: ElementRef, injector: Injector) { + super('ng1a', elementRef, injector); + } + } - @Directive({selector: 'ng1b'}) - class Ng1bComponent extends UpgradeComponent { - constructor(elementRef: ElementRef, injector: Injector) { - super('ng1b', elementRef, injector); - } - } + @Directive({selector: 'ng1b'}) + class Ng1bComponent extends UpgradeComponent { + constructor(elementRef: ElementRef, injector: Injector) { + super('ng1b', elementRef, injector); + } + } - @Component({ - selector: 'ng2', - template: `{{l('2A')}}{{l('2B')}}{{l('2C')}}` - }) - class Ng2Component { - l = l; - } + @Component({ + selector: 'ng2', + template: `{{l('2A')}}{{l('2B')}}{{l('2C')}}` + }) + class Ng2Component { + l = l; + } - @NgModule({ - declarations: [Ng1aComponent, Ng1bComponent, Ng2Component], - entryComponents: [Ng2Component], - imports: [BrowserModule, UpgradeModule] - }) - class Ng2Module { - ngDoBootstrap() {} - } + @NgModule({ + declarations: [Ng1aComponent, Ng1bComponent, Ng2Component], + entryComponents: [Ng2Component], + imports: [BrowserModule, UpgradeModule] + }) + class Ng2Module { + ngDoBootstrap() {} + } - const ng1Module = angular.module('ng1', []) - .directive('ng1a', () => ({template: '{{ l(\'ng1a\') }}'})) - .directive('ng1b', () => ({template: '{{ l(\'ng1b\') }}'})) - .directive('ng2', downgradeComponent({component: Ng2Component})) - .run(($rootScope: angular.IRootScopeService) => { - $rootScope.l = l; - $rootScope.reset = () => log.length = 0; - }); + const ng1Module = angular.module('ng1', []) + .directive('ng1a', () => ({template: '{{ l(\'ng1a\') }}'})) + .directive('ng1b', () => ({template: '{{ l(\'ng1b\') }}'})) + .directive('ng2', downgradeComponent({component: Ng2Component})) + .run(($rootScope: angular.IRootScopeService) => { + $rootScope.l = l; + $rootScope.reset = () => log.length = 0; + }); - const element = - html('
{{reset(); l(\'1A\');}}{{l(\'1B\')}}{{l(\'1C\')}}
'); - bootstrap(platformBrowserDynamic(), Ng2Module, element, ng1Module).then((upgrade) => { - expect(document.body.textContent).toEqual('1A;2A;ng1a;2B;ng1b;2C;1C;'); - expect(log).toEqual(['1A', '1C', '2A', '2B', '2C', 'ng1a', 'ng1b']); - }); - })); + const element = + html('
{{reset(); l(\'1A\');}}{{l(\'1B\')}}{{l(\'1C\')}}
'); + bootstrap(platformBrowserDynamic(), Ng2Module, element, ng1Module).then((upgrade) => { + expect(document.body.textContent).toEqual('1A;2A;ng1a;2B;ng1b;2C;1C;'); + expect(log).toEqual(['1A', '1C', '2A', '2B', '2C', 'ng1a', 'ng1b']); + }); + })); it('should propagate changes to a downgraded component inside the ngZone', async(() => { const element = html('');