refactor(TypeScript): Add noImplicitAny

We automatically insert explicit 'any's where needed. These need to be
addressed as in #9100.

Fixes #4924
This commit is contained in:
ScottSWu
2016-06-08 15:45:15 -07:00
parent 87d824e1b4
commit 86fbd50c3d
305 changed files with 2338 additions and 2337 deletions

View File

@ -23,7 +23,7 @@ export function main() {
() => [HashLocationStrategy, {provide: PlatformLocation, useClass: SpyPlatformLocation}]);
describe('without APP_BASE_HREF', () => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -63,7 +63,7 @@ export function main() {
describe('with APP_BASE_HREF with neither leading nor trailing slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: 'app'}]);
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -96,7 +96,7 @@ export function main() {
describe('with APP_BASE_HREF with leading slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: '/app'}]);
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -129,7 +129,7 @@ export function main() {
describe('with APP_BASE_HREF with both leading and trailing slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: '/app/'}]);
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -160,7 +160,7 @@ export function main() {
});
describe('hashLocationStrategy bugs', () => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, HashLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');

View File

@ -17,7 +17,7 @@ import {MockLocationStrategy} from '@angular/common/testing';
export function main() {
describe('Location', () => {
var locationStrategy, location;
var locationStrategy: any /** TODO #9100 */, location: any /** TODO #9100 */;
function makeLocation(baseHref: string = '/my/app',
provider: any = /*@ts2dart_const*/[]): Location {
@ -43,9 +43,9 @@ export function main() {
expect(locationStrategy.path()).toEqual('/my/app/user/btford');
});
it('should normalize urls on popstate', inject([AsyncTestCompleter], (async) => {
it('should normalize urls on popstate', inject([AsyncTestCompleter], (async: any /** TODO #9100 */) => {
location.subscribe((ev) => {
location.subscribe((ev: any /** TODO #9100 */) => {
expect(ev['url']).toEqual('/user/btford');
async.done();
});
@ -56,7 +56,7 @@ export function main() {
var locationStrategy = new MockLocationStrategy();
var location = new Location(locationStrategy);
function assertUrl(path) { expect(location.path()).toEqual(path); }
function assertUrl(path: any /** TODO #9100 */) { expect(location.path()).toEqual(path); }
location.go('/ready');
assertUrl('/ready');

View File

@ -20,7 +20,7 @@ import {SpyPlatformLocation} from '../spies';
export function main() {
describe('PathLocationStrategy', () => {
var platformLocation, locationStrategy;
var platformLocation: any /** TODO #9100 */, locationStrategy: any /** TODO #9100 */;
beforeEachProviders(() => [
PathLocationStrategy,
@ -38,7 +38,7 @@ export function main() {
});
describe('without APP_BASE_HREF', () => {
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
}));
@ -69,7 +69,7 @@ export function main() {
describe('with APP_BASE_HREF with neither leading nor trailing slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: 'app'}]);
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -102,7 +102,7 @@ export function main() {
describe('with APP_BASE_HREF with leading slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: '/app'}]);
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');
@ -135,7 +135,7 @@ export function main() {
describe('with APP_BASE_HREF with both leading and trailing slash', () => {
beforeEachProviders(() => [{provide: APP_BASE_HREF, useValue: '/app/'}]);
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl, ls) => {
beforeEach(inject([PlatformLocation, PathLocationStrategy], (pl: any /** TODO #9100 */, ls: any /** TODO #9100 */) => {
platformLocation = pl;
locationStrategy = ls;
platformLocation.spy('pushState');