From 3393fdc528a2284e95b665d55d2e42a1f34a3d22 Mon Sep 17 00:00:00 2001 From: Tom Scanlan Date: Sun, 24 Sep 2023 15:41:10 -0400 Subject: [PATCH] more specific registry index not found msg --- src/cargo/util/config/mod.rs | 5 ++++- tests/testsuite/source_replacement.rs | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/cargo/util/config/mod.rs b/src/cargo/util/config/mod.rs index d6fba5db9de..45a96921a7b 100644 --- a/src/cargo/util/config/mod.rs +++ b/src/cargo/util/config/mod.rs @@ -1546,7 +1546,10 @@ impl Config { ) }) } else { - bail!("no index found for registry: `{}`", registry); + bail!( + "registry index was not found in any configuration: `{}`", + registry + ); } } diff --git a/tests/testsuite/source_replacement.rs b/tests/testsuite/source_replacement.rs index 24f2ca3e3e3..6bde8a086ac 100644 --- a/tests/testsuite/source_replacement.rs +++ b/tests/testsuite/source_replacement.rs @@ -243,7 +243,7 @@ fn undefined_default() { .replace_crates_io(crates_io.index_url()) .with_status(101) .with_stderr( - "[ERROR] no index found for registry: `undefined` + "[ERROR] registry index was not found in any configuration: `undefined` ", ) .run();