From 5d3d8b8330dbb48ea3e82193440c5d23d067bba8 Mon Sep 17 00:00:00 2001 From: Sonu Kapoor Date: Wed, 15 Jul 2020 09:07:37 -0400 Subject: [PATCH] docs: add known issue for bazel (#38074) This commit adds a known issue for windows, when running tests using `bazal run`, instead of using `bazel test` PR Close #38074 --- docs/BAZEL.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/docs/BAZEL.md b/docs/BAZEL.md index 4a2784ca7e..40f5334341 100644 --- a/docs/BAZEL.md +++ b/docs/BAZEL.md @@ -254,6 +254,29 @@ Usually there is a single item (or multiple items of the same kind) where the ov ## Known issues +### Windows + +If you see the following error: + +``` +Error: Cannot find module 'C:\users\xxxx\_bazel_xxxx\7lxopdvs\execroot\angular\bazel-out\x64_windows-fastbuild\bin\packages\core\test\bundling\hello_world\symbol_test.bat.runfiles\angular\c;C:\msys64\users\xxxx\_bazel_xxxx\7lxopdvs\execroot\angular\bazel-out\x64_windows-fastbuild\bin\packages\core\test\bundling\hello_world\symbol_test.bat.runfiles\angular\packages\core\test\bundling\hello_world\symbol_test_require_patch.js' +Require stack: +- internal/preload + at Function.Module._resolveFilename (internal/modules/cjs/loader.js:793:17) + at Function.Module._load (internal/modules/cjs/loader.js:686:27) + at Module.require (internal/modules/cjs/loader.js:848:19) + at Module._preloadModules (internal/modules/cjs/loader.js:1133:12) + at loadPreloadModules (internal/bootstrap/pre_execution.js:443:5) + at prepareMainThreadExecution (internal/bootstrap/pre_execution.js:62:3) + at internal/main/run_main_module.js:7:1 { + code: 'MODULE_NOT_FOUND', + requireStack: [ 'internal/preload' ] +``` + +`bazel run` only works in Bazel Windows with non-test targets. Ensure that you are using `bazel test` instead. + +e.g: `yarn bazel test packages/core/test/bundling/forms:symbol_test --config=ivy` + ### Xcode If you see the following error: