Skip to content

Commit b97a21c

Browse files
committed
fix: conditionally set preserveSymlinks and add karma dependency
In `ng_config.bzl`, `preserveSymlinks` is now only set for test builders other than `@angular/build:unit-test`, preventing override issues. The `karma` package is added as an explicit dependency in `ng_test.bzl` to ensure tests run correctly.
1 parent 1f1aa3e commit b97a21c

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

src/architect/ng_config.bzl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,11 @@ JQ_DIST_REPLACE_TSCONFIG = """
1919
JQ_DIST_REPLACE_ANGULAR = """
2020
(
2121
.projects | to_entries | map(
22-
.value.architect.test.options.preserveSymlinks = true
22+
if .value.architect.test.builder != "@angular/build:unit-test" then
23+
.value.architect.test.options.preserveSymlinks = true
24+
else
25+
.
26+
end
2327
|
2428
if .value.projectType == "application" then
2529
.value.architect.build.options.outputPath = "./" + .value.root + "/dist"

src/architect/ng_test.bzl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ NPM_DEPS = lambda node_modules: ["/".join([node_modules, s]) for s in [
1313
"@types/jasmine",
1414
"@types/node",
1515
"jasmine-core",
16+
"karma",
1617
"karma-chrome-launcher",
1718
"karma-coverage",
1819
"karma-jasmine",

0 commit comments

Comments
 (0)