From d413ad8f64498fa5933fe5fd8e190b16415354a7 Mon Sep 17 00:00:00 2001 From: onur-ozkan Date: Wed, 6 Mar 2024 15:36:52 +0300 Subject: [PATCH 1/2] update remap path of `rust-analyzer-proc-macro-srv` alias Signed-off-by: onur-ozkan --- src/bootstrap/src/core/builder.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bootstrap/src/core/builder.rs b/src/bootstrap/src/core/builder.rs index 8223a80c93107..71283783f9e31 100644 --- a/src/bootstrap/src/core/builder.rs +++ b/src/bootstrap/src/core/builder.rs @@ -291,7 +291,7 @@ impl PathSet { const PATH_REMAP: &[(&str, &[&str])] = &[ // config.toml uses `rust-analyzer-proc-macro-srv`, but the // actual path is `proc-macro-srv-cli` - ("rust-analyzer-proc-macro-srv", &["proc-macro-srv-cli"]), + ("rust-analyzer-proc-macro-srv", &["src/tools/rust-analyzer/crates/proc-macro-srv-cli"]), // Make `x test tests` function the same as `x t tests/*` ( "tests", From ea22e7851f2d97b63379685258b482deb2409b8f Mon Sep 17 00:00:00 2001 From: onur-ozkan Date: Wed, 6 Mar 2024 15:37:21 +0300 Subject: [PATCH 2/2] validate `builder::PATH_REMAP` in bootstrap tests Signed-off-by: onur-ozkan --- src/bootstrap/src/core/builder/tests.rs | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/bootstrap/src/core/builder/tests.rs b/src/bootstrap/src/core/builder/tests.rs index 2cbebbcf4e2af..e402a0ba8bc7d 100644 --- a/src/bootstrap/src/core/builder/tests.rs +++ b/src/bootstrap/src/core/builder/tests.rs @@ -115,6 +115,19 @@ fn test_intersection() { assert_eq!(command_paths, vec![Path::new("library/stdarch")]); } +#[test] +fn validate_path_remap() { + let build = Build::new(configure("test", &["A"], &["A"])); + + PATH_REMAP + .iter() + .flat_map(|(_, paths)| paths.iter()) + .map(|path| build.src.join(path)) + .for_each(|path| { + assert!(path.exists(), "{} should exist.", path.display()); + }); +} + #[test] fn test_exclude() { let mut config = configure("test", &["A"], &["A"]);