angular-cn/packages/compiler/test/BUILD.bazel

68 lines
1.5 KiB
Python

load("//tools:defaults.bzl", "ts_library", "ts_web_test")
load("@build_bazel_rules_nodejs//:defs.bzl", "jasmine_node_test")
# Test that should only be run in node
NODE_ONLY = [
"**/*_node_only_spec.ts",
"aot/**/*.ts",
"render3/**/*.ts",
]
ts_library(
name = "test_lib",
testonly = 1,
srcs = glob(
["**/*.ts"],
exclude = NODE_ONLY,
),
deps = [
"//packages:types",
"//packages/common",
"//packages/compiler",
"//packages/compiler/testing",
"//packages/core",
"//packages/core/testing",
"//packages/platform-browser",
"//packages/platform-browser-dynamic",
"//packages/platform-browser/testing",
],
)
ts_library(
name = "test_node_only_lib",
testonly = 1,
srcs = glob(NODE_ONLY),
deps = [
":test_lib",
"//packages/compiler",
"//packages/compiler-cli",
"//packages/compiler/testing",
"//packages/core",
],
)
jasmine_node_test(
name = "test",
bootstrap = ["angular/tools/testing/init_node_spec.js"],
data = [
"//packages/animations:npm_package",
"//packages/common:npm_package",
"//packages/core:npm_package",
],
# dissable since tests are running but not yet passing
deps = [
":test_lib",
":test_node_only_lib",
"//packages/core",
"//tools/testing:node",
],
)
ts_web_test(
name = "test_web",
# disable since tests are running but not yet passing
deps = [
":test_lib",
],
)