Skip to content

Commit d25d7aa

Browse files
committed
detect missing patch target as missing dependency
1 parent af04ab9 commit d25d7aa

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/prepare.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,8 @@ fn run_command(cmd: Command) -> anyhow::Result<()> {
155155
|| line.contains("no matching package named")
156156
|| line.contains("no matching package found")
157157
|| line.contains("no matching package for override ")
158+
|| (line.contains("The patch location ")
159+
&& line.contains(" does not appear to contain any packages matching the name "))
158160
{
159161
missing_deps = true;
160162
} else if line.contains("failed to parse manifest at")

tests/buildtest/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ test_prepare_uncategorized_err!(
344344
"error: package collision in the lockfile: packages lockfile-collision v0.1.0 "
345345
);
346346

347-
test_prepare_uncategorized_err!(
347+
test_prepare_error_stderr!(
348348
test_invalid_cargotoml_missing_patch,
349349
"invalid-cargotoml-missing-patch",
350350
MissingDependencies,

0 commit comments

Comments
 (0)