effectiveFailureDetails property
TestFailureDetails?
get
effectiveFailureDetails
The failure details represented by the canonical JSON projection.
Older execution paths only populated message. Keeping this fallback here means compact history and richer report formats expose the same inferred failure kind instead of disagreeing about whether a kind exists.
Implementation
TestFailureDetails? get effectiveFailureDetails {
if (status != TestStatus.failed) return null;
final details = failure;
if (details != null && details.message.trim().isNotEmpty) return details;
if (details != null) {
return TestFailureDetails(
kind: details.kind,
message: effectiveFailureMessage,
target: details.target,
phase: details.phase,
);
}
return TestFailureDetails.fromMessage(effectiveFailureMessage);
}