Skip to content

Commit 5549c19

Browse files
committed
detect missing patch target as missing dependency
1 parent 9a2c168 commit 5549c19

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/prepare.rs

+2
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,8 @@ fn run_command(cmd: Command) -> anyhow::Result<()> {
156156
|| line.contains("no matching package found")
157157
|| line.contains("registry index was not found in any configuration:")
158158
|| line.contains("no matching package for override ")
159+
|| (line.contains("The patch location ")
160+
&& line.contains(" does not appear to contain any packages matching the name "))
159161
{
160162
missing_deps = true;
161163
} else if line.contains("failed to parse manifest at")

tests/buildtest/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ test_prepare_unknown_err!(
345345
"error: package collision in the lockfile: packages lockfile-collision v0.1.0 "
346346
);
347347

348-
test_prepare_unknown_err!(
348+
test_prepare_error_stderr!(
349349
test_invalid_cargotoml_missing_patch,
350350
"invalid-cargotoml-missing-patch",
351351
MissingDependencies,

0 commit comments

Comments
 (0)