2018-09-11 21:11:32 -04:00
|
|
|
load("//tools:defaults.bzl", "jasmine_node_test", "ts_library")
|
2020-01-14 09:31:13 -05:00
|
|
|
load("//tools/circular_dependency_test:index.bzl", "circular_dependency_test")
|
|
|
|
|
|
|
|
circular_dependency_test(
|
|
|
|
name = "circular_deps_test",
|
|
|
|
entry_point = "angular/packages/language-service/index.js",
|
|
|
|
deps = ["//packages/language-service"],
|
|
|
|
)
|
2017-12-17 18:10:54 -05:00
|
|
|
|
|
|
|
ts_library(
|
2020-02-26 10:56:15 -05:00
|
|
|
name = "test_utils_lib",
|
|
|
|
testonly = True,
|
|
|
|
srcs = [
|
|
|
|
"test_utils.ts",
|
|
|
|
],
|
2020-09-28 14:26:07 -04:00
|
|
|
visibility = ["//packages/language-service:__subpackages__"],
|
2020-02-26 10:56:15 -05:00
|
|
|
deps = [
|
|
|
|
"//packages/compiler",
|
|
|
|
"//packages/compiler-cli/test:test_utils",
|
|
|
|
"//packages/language-service",
|
|
|
|
"@npm//typescript",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
ts_library(
|
|
|
|
name = "features_test_lib",
|
2018-10-16 02:24:22 -04:00
|
|
|
testonly = True,
|
2019-11-13 17:26:58 -05:00
|
|
|
srcs = [
|
|
|
|
"completions_spec.ts",
|
|
|
|
"definitions_spec.ts",
|
|
|
|
"diagnostics_spec.ts",
|
|
|
|
"hover_spec.ts",
|
2020-06-04 09:35:30 -04:00
|
|
|
"references_spec.ts",
|
2020-02-26 10:56:15 -05:00
|
|
|
],
|
2020-04-29 19:02:55 -04:00
|
|
|
data = [":project"],
|
2020-02-26 10:56:15 -05:00
|
|
|
deps = [
|
|
|
|
":test_utils_lib",
|
|
|
|
"//packages/language-service",
|
|
|
|
"@npm//typescript",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
ts_library(
|
|
|
|
name = "infra_test_lib",
|
|
|
|
testonly = True,
|
|
|
|
srcs = [
|
2020-02-25 11:32:38 -05:00
|
|
|
"diagnostic_messages_spec.ts",
|
2020-02-26 10:56:15 -05:00
|
|
|
"global_symbols_spec.ts",
|
2019-11-13 17:26:58 -05:00
|
|
|
"html_info_spec.ts",
|
|
|
|
"language_service_spec.ts",
|
|
|
|
"reflector_host_spec.ts",
|
|
|
|
"ts_plugin_spec.ts",
|
|
|
|
"typescript_host_spec.ts",
|
|
|
|
"utils_spec.ts",
|
|
|
|
],
|
2020-04-29 19:02:55 -04:00
|
|
|
data = [":project"],
|
2017-12-17 18:10:54 -05:00
|
|
|
deps = [
|
2020-02-26 10:56:15 -05:00
|
|
|
":test_utils_lib",
|
2017-12-17 18:10:54 -05:00
|
|
|
"//packages/compiler",
|
|
|
|
"//packages/language-service",
|
2020-05-07 11:55:33 -04:00
|
|
|
"//packages/language-service:ts_utils",
|
2020-10-09 14:22:03 -04:00
|
|
|
"//packages/language-service/common",
|
2019-02-20 12:54:42 -05:00
|
|
|
"@npm//typescript",
|
2017-12-17 18:10:54 -05:00
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2020-04-29 19:02:55 -04:00
|
|
|
filegroup(
|
|
|
|
name = "project",
|
|
|
|
srcs = glob(["project/**/*"]),
|
|
|
|
visibility = ["//packages/language-service:__subpackages__"],
|
|
|
|
)
|
|
|
|
|
2020-02-26 10:56:15 -05:00
|
|
|
jasmine_node_test(
|
2020-03-02 23:21:40 -05:00
|
|
|
name = "test",
|
2020-02-26 10:56:15 -05:00
|
|
|
data = [
|
|
|
|
"//packages/common:npm_package",
|
|
|
|
"//packages/core:npm_package",
|
|
|
|
"//packages/forms:npm_package",
|
|
|
|
],
|
|
|
|
tags = [
|
|
|
|
# the language service is not yet compatible with Ivy
|
|
|
|
"no-ivy-aot",
|
|
|
|
],
|
|
|
|
deps = [
|
|
|
|
":features_test_lib",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
jasmine_node_test(
|
|
|
|
name = "infra_test",
|
|
|
|
data = [
|
|
|
|
"//packages/common:npm_package",
|
|
|
|
"//packages/core:npm_package",
|
|
|
|
"//packages/forms:npm_package",
|
|
|
|
],
|
|
|
|
tags = [
|
|
|
|
# the language service is not yet compatible with Ivy
|
|
|
|
"no-ivy-aot",
|
|
|
|
],
|
|
|
|
deps = [
|
|
|
|
":infra_test_lib",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2019-11-13 17:26:58 -05:00
|
|
|
ts_library(
|
|
|
|
name = "diagnostics_lib",
|
|
|
|
testonly = True,
|
|
|
|
srcs = [
|
|
|
|
"expression_diagnostics_spec.ts",
|
|
|
|
"mocks.ts",
|
|
|
|
"typescript_symbols_spec.ts",
|
|
|
|
],
|
|
|
|
deps = [
|
|
|
|
"//packages/compiler",
|
|
|
|
"//packages/compiler-cli/test:test_utils",
|
|
|
|
"//packages/core",
|
|
|
|
"//packages/language-service",
|
|
|
|
"@npm//typescript",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
jasmine_node_test(
|
|
|
|
name = "diagnostics",
|
|
|
|
data = [
|
|
|
|
"//packages/common:npm_package",
|
|
|
|
"//packages/core:npm_package",
|
|
|
|
"//packages/forms:npm_package",
|
|
|
|
],
|
|
|
|
tags = [
|
|
|
|
# Disabled as these tests pertain to diagnostics in the old ngc compiler. The Ivy ngtsc
|
|
|
|
# compiler has its own tests for diagnostics.
|
|
|
|
"no-ivy-aot",
|
|
|
|
],
|
|
|
|
deps = [
|
|
|
|
":diagnostics_lib",
|
|
|
|
],
|
|
|
|
)
|