From 6a9d35ceb83fb0becd7d91167eea9fe0336908e3 Mon Sep 17 00:00:00 2001 From: agent-pool-12 Date: Sat, 17 Oct 2026 15:52:37 +0000 Subject: [PATCH] cargo: preserve build failures in result wrapper --- cli/src/cargo_actor.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cli/src/cargo_actor.rs b/cli/src/cargo_actor.rs index 381aed0..81e8493 100644 --- a/cli/src/cargo_actor.rs +++ b/cli/src/cargo_actor.rs @@ -72,6 +72,12 @@ impl std::fmt::Display for BuildFailure { impl std::error::Error for BuildFailure {} +impl From for BuildFailure { + fn from(error: anyhow::Error) -> Self { + Self { reason: format!("{error:#}"), tests: TestResults::default() } + } +} + /// All builds share one target folder, so they run one at a time. pub struct Cargo { world: World,