Previously the compiler compliance tests ran and built test code with real dependencies on @angular/core and @angular/common. This meant that any changes to the compiler would result in long rebuild processes for tests to rerun. This change removes those dependencies and causes test code to be built against the fake_core stub of @angular/core that the ngtsc tests use. This change also removes the dependency on @angular/common entirely, as locality means it's possible to reference *ngIf without needing to link to an implementation. PR Close #25248
33 lines
723 B
Python
33 lines
723 B
Python
load("//tools:defaults.bzl", "ts_library")
|
|
load("@build_bazel_rules_nodejs//:defs.bzl", "jasmine_node_test")
|
|
|
|
ts_library(
|
|
name = "test_lib",
|
|
testonly = 1,
|
|
srcs = glob(
|
|
["**/*.ts"],
|
|
),
|
|
deps = [
|
|
"//packages:types",
|
|
"//packages/compiler",
|
|
"//packages/compiler-cli",
|
|
"//packages/compiler/test:test_utils",
|
|
],
|
|
)
|
|
|
|
jasmine_node_test(
|
|
name = "compliance",
|
|
bootstrap = ["angular/tools/testing/init_node_no_angular_spec.js"],
|
|
data = [
|
|
"//packages/compiler-cli/test/ngtsc/fake_core:npm_package",
|
|
],
|
|
tags = [
|
|
"ivy-local",
|
|
"ivy-only",
|
|
],
|
|
deps = [
|
|
":test_lib",
|
|
"//tools/testing:node_no_angular",
|
|
],
|
|
)
|