From 86fbd50c3d069667ee942b9fd53e7374dfec9733 Mon Sep 17 00:00:00 2001 From: ScottSWu Date: Wed, 8 Jun 2016 15:45:15 -0700 Subject: [PATCH] refactor(TypeScript): Add noImplicitAny We automatically insert explicit 'any's where needed. These need to be addressed as in #9100. Fixes #4924 --- .../@angular/common/src/directives/ng_for.ts | 2 +- .../common/test/directives/ng_class_spec.ts | 54 ++--- .../common/test/directives/ng_for_spec.ts | 52 ++--- .../common/test/directives/ng_if_spec.ts | 18 +- .../common/test/directives/ng_plural_spec.ts | 8 +- .../common/test/directives/ng_style_spec.ts | 14 +- .../common/test/directives/ng_switch_spec.ts | 8 +- .../directives/ng_template_outlet_spec.ts | 8 +- .../test/directives/non_bindable_spec.ts | 6 +- .../test/forms-deprecated/directives_spec.ts | 48 ++-- .../forms-deprecated/form_builder_spec.ts | 6 +- .../test/forms-deprecated/integration_spec.ts | 102 ++++----- .../test/forms-deprecated/model_spec.ts | 66 +++--- .../test/forms-deprecated/validators_spec.ts | 12 +- .../common/test/pipes/async_pipe_spec.ts | 26 +-- .../common/test/pipes/date_pipe_spec.ts | 4 +- .../test/pipes/i18n_plural_pipe_spec.ts | 4 +- .../test/pipes/i18n_select_pipe_spec.ts | 4 +- .../common/test/pipes/json_pipe_spec.ts | 8 +- .../common/test/pipes/lowercase_pipe_spec.ts | 6 +- .../common/test/pipes/number_pipe_spec.ts | 6 +- .../common/test/pipes/replace_pipe_spec.ts | 6 +- .../common/test/pipes/slice_pipe_spec.ts | 6 +- .../common/test/pipes/uppercase_pipe_spec.ts | 6 +- .../src/animation/animation_compiler.ts | 20 +- .../src/animation/animation_parser.ts | 40 ++-- .../@angular/compiler/src/compile_metadata.ts | 4 +- modules/@angular/compiler/src/config.ts | 10 +- modules/@angular/compiler/src/css/lexer.ts | 10 +- modules/@angular/compiler/src/css/parser.ts | 38 ++-- .../src/directive_lifecycle_reflector.ts | 2 +- .../compiler/src/directive_resolver.ts | 6 +- .../compiler/src/expression_parser/ast.ts | 2 +- .../compiler/src/expression_parser/lexer.ts | 4 +- .../compiler/src/expression_parser/parser.ts | 28 +-- modules/@angular/compiler/src/html_ast.ts | 2 +- modules/@angular/compiler/src/html_lexer.ts | 24 +- modules/@angular/compiler/src/html_parser.ts | 6 +- .../compiler/src/i18n/i18n_html_parser.ts | 6 +- modules/@angular/compiler/src/i18n/shared.ts | 4 +- .../compiler/src/i18n/xmb_serializer.ts | 4 +- .../compiler/src/metadata_resolver.ts | 28 +-- .../@angular/compiler/src/offline_compiler.ts | 6 +- .../compiler/src/output/abstract_emitter.ts | 8 +- .../src/output/abstract_js_emitter.ts | 4 +- .../compiler/src/output/dart_emitter.ts | 10 +- .../compiler/src/output/dart_imports.ts | 2 +- .../compiler/src/output/js_emitter.ts | 2 +- .../compiler/src/output/output_ast.ts | 2 +- .../compiler/src/output/output_interpreter.ts | 26 +-- .../compiler/src/output/output_jit.ts | 2 +- .../compiler/src/output/ts_emitter.ts | 10 +- .../@angular/compiler/src/provider_parser.ts | 2 +- .../@angular/compiler/src/runtime_compiler.ts | 8 +- .../src/schema/dom_element_schema_registry.ts | 2 +- modules/@angular/compiler/src/selector.ts | 14 +- modules/@angular/compiler/src/shadow_css.ts | 24 +- .../@angular/compiler/src/style_compiler.ts | 2 +- .../compiler/src/style_url_resolver.ts | 4 +- modules/@angular/compiler/src/template_ast.ts | 2 +- .../@angular/compiler/src/template_parser.ts | 26 +-- .../compiler/src/template_preparser.ts | 6 +- modules/@angular/compiler/src/url_resolver.ts | 2 +- modules/@angular/compiler/src/util.ts | 6 +- .../src/view_compiler/compile_element.ts | 18 +- .../src/view_compiler/compile_query.ts | 2 +- .../src/view_compiler/event_binder.ts | 4 +- .../src/view_compiler/expression_converter.ts | 10 +- .../src/view_compiler/property_binder.ts | 2 +- .../compiler/src/view_compiler/util.ts | 2 +- .../src/view_compiler/view_builder.ts | 28 +-- .../src/view_compiler/view_compiler.ts | 4 +- .../test/animation/animation_compiler_spec.ts | 2 +- .../test/animation/animation_parser_spec.ts | 6 +- .../@angular/compiler/test/css/lexer_spec.ts | 16 +- .../@angular/compiler/test/css/parser_spec.ts | 6 +- .../compiler/test/css/visitor_spec.ts | 10 +- .../compiler/test/directive_lifecycle_spec.ts | 2 +- .../test/directive_normalizer_spec.ts | 16 +- .../compiler/test/directive_resolver_spec.ts | 34 +-- .../test/expression_parser/lexer_spec.ts | 14 +- .../test/expression_parser/parser_spec.ts | 14 +- .../test/i18n/i18n_html_parser_spec.ts | 2 +- .../compiler/test/offline_compiler_spec.ts | 2 +- .../test/output/output_emitter_spec.ts | 8 +- .../test/output/output_emitter_util.ts | 4 +- .../compiler/test/schema/schema_extractor.ts | 18 +- .../@angular/compiler/test/selector_spec.ts | 4 +- .../@angular/compiler/test/shadow_css_spec.ts | 8 +- .../compiler/test/style_url_resolver_spec.ts | 2 +- .../compiler/test/template_parser_spec.ts | 10 +- .../compiler/test/template_preparser_spec.ts | 2 +- .../test/test_component_builder_spec.ts | 46 ++-- .../@angular/compiler/test/xhr_mock_spec.ts | 16 +- .../testing/test_component_builder.ts | 12 +- .../compiler/testing/view_resolver_mock.ts | 2 +- modules/@angular/compiler/testing/xhr_mock.ts | 4 +- .../animation/active_animation_players_map.ts | 4 +- .../src/animation/animation_group_player.ts | 2 +- .../core/src/animation/animation_player.ts | 6 +- .../animation/animation_sequence_player.ts | 2 +- .../src/animation/animation_style_util.ts | 36 +-- .../@angular/core/src/animation/metadata.ts | 2 +- modules/@angular/core/src/application_ref.ts | 8 +- .../@angular/core/src/application_tokens.ts | 2 +- .../differs/default_iterable_differ.ts | 32 +-- .../differs/default_keyvalue_differ.ts | 16 +- .../differs/iterable_differs.ts | 2 +- .../differs/keyvalue_differs.ts | 4 +- modules/@angular/core/src/di/metadata.ts | 4 +- modules/@angular/core/src/di/provider.ts | 16 +- .../core/src/di/reflective_exceptions.ts | 16 +- .../core/src/di/reflective_injector.ts | 4 +- .../core/src/di/reflective_provider.ts | 22 +- .../core/src/linker/component_resolver.ts | 2 +- .../@angular/core/src/linker/debug_context.ts | 4 +- modules/@angular/core/src/linker/element.ts | 4 +- .../@angular/core/src/linker/query_list.ts | 2 +- .../src/linker/systemjs_component_resolver.ts | 2 +- modules/@angular/core/src/linker/view.ts | 8 +- modules/@angular/core/src/linker/view_ref.ts | 4 +- .../@angular/core/src/linker/view_utils.ts | 28 +-- .../core/src/metadata/lifecycle_hooks.ts | 16 +- modules/@angular/core/src/profile/wtf_impl.ts | 8 +- .../src/reflection/reflection_capabilities.ts | 8 +- modules/@angular/core/src/render/api.ts | 8 +- modules/@angular/core/src/util/decorators.ts | 18 +- .../@angular/core/src/zone/ng_zone_impl.ts | 8 +- .../active_animations_players_map_spec.ts | 4 +- .../animation/animation_group_player_spec.ts | 2 +- .../animation/animation_integration_spec.ts | 28 +-- .../animation_sequence_player_spec.ts | 2 +- .../animation/animation_style_util_spec.ts | 6 +- .../core/test/application_ref_spec.ts | 10 +- .../differs/default_iterable_differ_spec.ts | 10 +- .../differs/default_keyvalue_differ_spec.ts | 18 +- .../differs/iterable_differs_spec.ts | 6 +- .../core/test/change_detection/iterable.ts | 2 +- .../core/test/change_detection/util.ts | 6 +- .../core/test/debug/debug_node_spec.ts | 30 +-- .../core/test/di/reflective_injector_spec.ts | 22 +- .../directive_lifecycle_integration_spec.ts | 6 +- modules/@angular/core/test/dom/shim_spec.ts | 6 +- .../core/test/facade/observable_spec.ts | 12 +- modules/@angular/core/test/fake_async_spec.ts | 8 +- .../core/test/forward_ref_integration_spec.ts | 2 +- .../change_detection_integration_spec.ts | 36 +-- .../linker/dynamic_component_loader_spec.ts | 16 +- .../core/test/linker/integration_spec.ts | 212 +++++++++--------- .../linker/projection_integration_spec.ts | 54 ++--- .../test/linker/query_integration_spec.ts | 82 +++---- .../core/test/linker/query_list_spec.ts | 10 +- .../reflector_component_resolver_spec.ts | 8 +- .../linker/regression_integration_spec.ts | 18 +- .../test/linker/security_integration_spec.ts | 18 +- .../linker/view_injector_integration_spec.ts | 38 ++-- .../core/test/metadata/decorators_spec.ts | 2 +- .../@angular/core/test/metadata/di_spec.ts | 8 +- .../core/test/reflection/reflector_common.ts | 12 +- .../core/test/reflection/reflector_spec.ts | 34 +-- .../core/test/testability/testability_spec.ts | 22 +- .../core/test/testing_internal_spec.ts | 10 +- .../core/test/util/decorators_spec.ts | 6 +- .../@angular/core/test/zone/ng_zone_spec.ts | 54 ++--- .../animation/mock_animation_driver.ts | 4 +- .../animation/mock_animation_player.ts | 6 +- modules/@angular/core/testing/async.ts | 2 +- modules/@angular/core/testing/fake_async.ts | 4 +- modules/@angular/core/testing/lang_utils.ts | 2 +- modules/@angular/core/testing/logger.ts | 4 +- modules/@angular/core/testing/regexp.ts | 2 +- modules/@angular/core/testing/testing.ts | 2 +- .../@angular/core/testing/testing_internal.ts | 48 ++-- modules/@angular/facade/src/async.ts | 14 +- modules/@angular/facade/src/browser.ts | 2 +- modules/@angular/facade/src/collection.ts | 12 +- modules/@angular/facade/src/exceptions.ts | 4 +- modules/@angular/facade/src/intl.ts | 16 +- modules/@angular/facade/src/lang.ts | 32 +-- modules/@angular/facade/src/math.ts | 2 +- modules/@angular/facade/src/promise.ts | 2 +- modules/@angular/facade/test/async_spec.ts | 22 +- .../@angular/facade/test/collection_spec.ts | 4 +- modules/@angular/facade/test/lang_spec.ts | 8 +- .../@angular/http/src/backends/xhr_backend.ts | 2 +- modules/@angular/http/src/headers.ts | 6 +- modules/@angular/http/src/static_request.ts | 6 +- .../http/test/backends/xhr_backend_spec.ts | 6 +- modules/@angular/http/test/headers_spec.ts | 6 +- .../src/browser/browser_adapter.ts | 144 ++++++------ .../src/browser/testability.ts | 6 +- .../src/dom/debug/ng_probe.ts | 6 +- .../platform-browser/src/dom/dom_adapter.ts | 182 +++++++-------- .../platform-browser/src/dom/dom_renderer.ts | 18 +- .../src/dom/events/dom_events.ts | 4 +- .../src/dom/events/hammer_gestures.ts | 4 +- .../src/dom/events/key_events.ts | 2 +- .../src/dom/shared_styles_host.ts | 2 +- .../@angular/platform-browser/src/dom/util.ts | 4 +- .../src/dom/web_animations_driver.ts | 14 +- .../src/dom/web_animations_player.ts | 2 +- .../src/security/dom_sanitization_service.ts | 2 +- .../src/security/html_sanitizer.ts | 8 +- .../shared/client_message_broker.ts | 10 +- .../shared/service_message_broker.ts | 2 +- .../src/web_workers/ui/event_dispatcher.ts | 2 +- .../src/web_workers/ui/event_serializer.ts | 2 +- .../src/web_workers/ui/renderer.ts | 4 +- .../src/web_workers/worker/renderer.ts | 2 +- .../src/web_workers/worker/worker_adapter.ts | 170 +++++++------- .../platform-browser/src/worker_render.ts | 2 +- .../test/browser/bootstrap_spec.ts | 36 +-- .../test/browser/rectangle_mock.ts | 2 +- .../test/browser/tools/spies.ts | 4 +- .../test/dom/events/event_manager_spec.ts | 22 +- .../test/dom/shared_styles_host_spec.ts | 2 +- .../test/dom/web_animations_player_spec.ts | 2 +- .../test/testing_public_browser_spec.ts | 16 +- .../test/testing_public_spec.ts | 46 ++-- .../web_workers/shared/message_bus_spec.ts | 10 +- .../shared/service_message_broker_spec.ts | 6 +- .../shared/web_worker_test_util.ts | 2 +- .../worker/platform_location_spec.ts | 2 +- .../worker/renderer_integration_spec.ts | 18 +- .../test/xhr/xhr_cache_setter.ts | 2 +- .../test/xhr/xhr_cache_spec.ts | 4 +- .../test/xhr/xhr_impl_spec.ts | 4 +- .../testing/benchmark_util.ts | 8 +- .../platform-browser/testing/browser_util.ts | 10 +- .../testing/dom_test_component_renderer.ts | 2 +- .../platform-browser/testing/e2e_util.ts | 6 +- .../platform-browser/testing/matchers.ts | 44 ++-- .../platform-browser/testing/perf_util.ts | 24 +- .../platform-server/src/parse5_adapter.ts | 196 ++++++++-------- .../src/directives/router_outlet.ts | 2 +- .../router-deprecated/src/instruction.ts | 4 +- .../lifecycle/route_lifecycle_reflector.ts | 4 +- .../route_config/route_config_normalizer.ts | 2 +- .../router-deprecated/src/route_registry.ts | 12 +- .../@angular/router-deprecated/src/router.ts | 8 +- .../src/rules/route_paths/param_route_path.ts | 18 +- .../router-deprecated/src/rules/rule_set.ts | 6 +- .../router-deprecated/src/rules/rules.ts | 4 +- .../router-deprecated/src/url_parser.ts | 6 +- .../@angular/router-deprecated/src/utils.ts | 2 +- .../test/directives/router_link_spec.ts | 16 +- .../test/integration/bootstrap_spec.ts | 32 +-- .../integration/impl/async_route_spec_impl.ts | 156 ++++++------- .../integration/impl/aux_route_spec_impl.ts | 32 +-- .../integration/impl/sync_route_spec_impl.ts | 108 ++++----- .../test/integration/lifecycle_hook_spec.ts | 28 +-- .../test/integration/navigation_spec.ts | 34 +-- .../test/integration/redirect_route_spec.ts | 18 +- .../test/integration/router_link_spec.ts | 36 +-- .../test/integration/util.ts | 8 +- .../location/hash_location_strategy_spec.ts | 10 +- .../test/location/location_spec.ts | 8 +- .../location/path_location_strategy_spec.ts | 10 +- .../test/route_config/route_config_spec.ts | 36 +-- .../test/route_registry_spec.ts | 28 +-- .../router-deprecated/test/router_spec.ts | 34 +-- .../route_paths/regex_route_param_spec.ts | 4 +- .../test/rules/rule_set_spec.ts | 26 +-- modules/@angular/router-deprecated/testing.ts | 2 +- modules/@angular/router/src/link.ts | 4 +- modules/@angular/router/src/recognize.ts | 10 +- modules/@angular/router/src/router.ts | 8 +- .../router/src/router_url_serializer.ts | 4 +- modules/@angular/router/src/segments.ts | 2 +- .../@angular/router/test/integration_spec.ts | 40 ++-- .../@angular/router/test/recognize_spec.ts | 24 +- .../@angular/router/test/router_link_spec.ts | 6 +- .../testing/router_testing_providers.ts | 2 +- .../upgrade/src/downgrade_ng2_adapter.ts | 30 +-- modules/@angular/upgrade/src/metadata.ts | 2 +- .../@angular/upgrade/src/upgrade_adapter.ts | 8 +- .../upgrade/src/upgrade_ng1_adapter.ts | 26 +-- modules/@angular/upgrade/test/upgrade_spec.ts | 96 ++++---- modules/empty.ts | 2 +- .../e2e_test/alt_routing/routing_spec.ts | 2 +- .../hash_routing/hash_location_spec.ts | 2 +- .../e2e_test/hello_world/hello_world_spec.ts | 4 +- modules/playground/e2e_test/http/http_spec.ts | 2 +- .../playground/e2e_test/jsonp/jsonp_spec.ts | 2 +- .../e2e_test/relative_assets/assets_spec.ts | 4 +- .../e2e_test/routing/routing_spec.ts | 2 +- .../e2e_test/sourcemap/sourcemap_spec.ts | 4 +- .../web_workers/router/router_spec.ts | 2 +- .../src/alt_routing/app/inbox-app.ts | 6 +- .../playground/src/animate/app/animate-app.ts | 4 +- modules/playground/src/async/index.ts | 8 +- modules/playground/src/bootstrap.ts | 6 +- modules/playground/src/gestures/index.ts | 6 +- modules/playground/src/key_events/index.ts | 4 +- .../src/model_driven_forms/index.ts | 6 +- .../playground/src/routing/app/inbox-app.ts | 6 +- .../src/template_driven_forms/index.ts | 6 +- modules/playground/src/todo/index.ts | 6 +- modules/playground/src/upgrade/index.ts | 2 +- .../src/web_workers/images/index_common.ts | 4 +- .../src/web_workers/images/services/bitmap.ts | 4 +- .../src/web_workers/input/index_common.ts | 4 +- .../web_workers/kitchen_sink/index_common.ts | 2 +- .../src/web_workers/todo/index_common.ts | 4 +- modules/tsconfig.json | 1 + 305 files changed, 2338 insertions(+), 2337 deletions(-) diff --git a/modules/@angular/common/src/directives/ng_for.ts b/modules/@angular/common/src/directives/ng_for.ts index 860f767a0a..6afd39330a 100644 --- a/modules/@angular/common/src/directives/ng_for.ts +++ b/modules/@angular/common/src/directives/ng_for.ts @@ -144,7 +144,7 @@ export class NgFor implements DoCheck { viewRef.context.count = ilen; } - changes.forEachIdentityChange((record) => { + changes.forEachIdentityChange((record: any /** TODO #9100 */) => { var viewRef = >this._viewContainer.get(record.currentIndex); viewRef.context.$implicit = record.item; }); diff --git a/modules/@angular/common/test/directives/ng_class_spec.ts b/modules/@angular/common/test/directives/ng_class_spec.ts index 467dbd8410..cf0ab73739 100644 --- a/modules/@angular/common/test/directives/ng_class_spec.ts +++ b/modules/@angular/common/test/directives/ng_class_spec.ts @@ -25,7 +25,7 @@ export function main() { describe('binding to CSS class list', () => { it('should clean up when the directive is destroyed', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) .createAsync(TestComponent) @@ -44,7 +44,7 @@ export function main() { describe('expressions evaluating to objects', () => { it('should add classes specified in an object literal', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -57,7 +57,7 @@ export function main() { it('should add classes specified in an object literal without change in class names', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -69,7 +69,7 @@ export function main() { })); it('should add and remove classes based on changes in object literal values', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -85,7 +85,7 @@ export function main() { })); it('should add and remove classes based on changes to the expression object', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -107,7 +107,7 @@ export function main() { })); it('should add and remove classes based on reference changes to the expression object', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -126,7 +126,7 @@ export function main() { })); it('should remove active classes when expression evaluates to null', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -146,7 +146,7 @@ export function main() { it('should allow multiple classes per expression', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -171,7 +171,7 @@ export function main() { })); it('should split by one or more spaces between classes', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -190,7 +190,7 @@ export function main() { describe('expressions evaluating to lists', () => { it('should add classes specified in a list literal', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -202,7 +202,7 @@ export function main() { })); it('should add and remove classes based on changes to the expression', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -225,7 +225,7 @@ export function main() { })); it('should add and remove classes when a reference changes', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -241,7 +241,7 @@ export function main() { })); it('should take initial classes into account when a reference changes', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -257,7 +257,7 @@ export function main() { })); it('should ignore empty or blank class names', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -272,7 +272,7 @@ export function main() { })); it('should trim blanks from class names', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -288,7 +288,7 @@ export function main() { it('should allow multiple classes per item in arrays', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -310,7 +310,7 @@ export function main() { describe('expressions evaluating to sets', () => { it('should add and remove classes if the set instance changed', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -333,7 +333,7 @@ export function main() { describe('expressions evaluating to string', () => { it('should add classes specified in a string literal', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -345,7 +345,7 @@ export function main() { })); it('should add and remove classes based on changes to the expression', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -365,7 +365,7 @@ export function main() { })); it('should remove active classes when switching from string to null', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -381,7 +381,7 @@ export function main() { })); it('should take initial classes into account when switching from string to null', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -397,7 +397,7 @@ export function main() { })); it('should ignore empty and blank strings', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -415,7 +415,7 @@ export function main() { describe('cooperation with other class-changing constructs', () => { it('should co-operate with the class attribute', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) @@ -435,7 +435,7 @@ export function main() { })); it('should co-operate with the interpolated class attribute', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -455,7 +455,7 @@ export function main() { })); it('should co-operate with the class attribute and binding to it', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = `
`; tcb.overrideTemplate(TestComponent, template) @@ -475,7 +475,7 @@ export function main() { })); it('should co-operate with the class attribute and class.name binding', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; @@ -498,7 +498,7 @@ export function main() { })); it('should co-operate with initial class and class attribute binding when binding changes', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
'; tcb.overrideTemplate(TestComponent, template) diff --git a/modules/@angular/common/test/directives/ng_for_spec.ts b/modules/@angular/common/test/directives/ng_for_spec.ts index fb37c4c522..4b0f73e9c7 100644 --- a/modules/@angular/common/test/directives/ng_for_spec.ts +++ b/modules/@angular/common/test/directives/ng_for_spec.ts @@ -25,7 +25,7 @@ export function main() { '
{{item.toString()}};
'; it('should reflect initial elements', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -36,7 +36,7 @@ export function main() { })); it('should reflect added elements', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -51,7 +51,7 @@ export function main() { })); it('should reflect removed elements', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -66,7 +66,7 @@ export function main() { })); it('should reflect moved elements', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -82,7 +82,7 @@ export function main() { })); it('should reflect a mix of all changes (additions/removals/moves)', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -98,7 +98,7 @@ export function main() { })); it('should iterate over an array of objects', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = ''; tcb.overrideTemplate(TestComponent, template) @@ -128,7 +128,7 @@ export function main() { })); it('should gracefully handle nulls', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = ''; tcb.overrideTemplate(TestComponent, template) .createAsync(TestComponent) @@ -140,7 +140,7 @@ export function main() { })); it('should gracefully handle ref changing to null and back', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -160,7 +160,7 @@ export function main() { if (!IS_DART) { it('should throw on non-iterable ref and suggest using an array', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -177,7 +177,7 @@ export function main() { } it('should throw on ref changing to string', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -191,7 +191,7 @@ export function main() { })); it('should works with duplicates', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { tcb.overrideTemplate(TestComponent, TEMPLATE) .createAsync(TestComponent) .then((fixture) => { @@ -204,7 +204,7 @@ export function main() { })); it('should repeat over nested arrays', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '
' + '
' + '
' + @@ -231,7 +231,7 @@ export function main() { })); it('should repeat over nested arrays with no intermediate element', - inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async) => { + inject([TestComponentBuilder, AsyncTestCompleter], (tcb: TestComponentBuilder, async: any /** TODO #9100 */) => { var template = '