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

@ -1,3 +1,3 @@
export function setTemplateCache(cache): void {
export function setTemplateCache(cache: any /** TODO #9100 */): void {
(<any>window).$templateCache = cache;
}

View File

@ -43,7 +43,7 @@ export function main() {
});
it('should resolve the Promise with the cached file content on success',
inject([AsyncTestCompleter], (async) => {
inject([AsyncTestCompleter], (async: any /** TODO #9100 */) => {
setTemplateCache({'test.html': '<div>Hello</div>'});
xhr = new CachedXHR();
xhr.get('test.html')
@ -53,7 +53,7 @@ export function main() {
});
}));
it('should reject the Promise on failure', inject([AsyncTestCompleter], (async) => {
it('should reject the Promise on failure', inject([AsyncTestCompleter], (async: any /** TODO #9100 */) => {
xhr = new CachedXHR();
xhr.get('unknown.html')
.then((text) => { throw new BaseException('Not expected to succeed.'); })

View File

@ -28,14 +28,14 @@ export function main() {
beforeEach(() => { xhr = new XHRImpl(); });
it('should resolve the Promise with the file content on success',
inject([AsyncTestCompleter], (async) => {
inject([AsyncTestCompleter], (async: any /** TODO #9100 */) => {
xhr.get(url200).then((text) => {
expect(text.trim()).toEqual('<p>hey</p>');
async.done();
});
}), 10000);
it('should reject the Promise on failure', inject([AsyncTestCompleter], (async) => {
it('should reject the Promise on failure', inject([AsyncTestCompleter], (async: any /** TODO #9100 */) => {
PromiseWrapper.catchError(xhr.get(url404), (e) => {
expect(e).toEqual(`Failed to load ${url404}`);
async.done();