Engine blend-fit test: solidcore is the only kernel, so the refusal always names its edge

The cherry-picked test asked kernel_route which kernel ran; that choice is gone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DtL5M41G8Nua7HvuFPZkmJ
This commit is contained in:
jyviko
2026-11-02 20:38:25 -05:00
parent c97092e385
commit 3131b933c7
+4 -5
View File
@@ -46,19 +46,18 @@ fn chamfer_that_fits_still_builds() {
}
/// #199's bar, 14 x 6 x 10, its four upright edges rounded: past a full round of its 6 mm ends
/// the two rounds on each end would cross. Refused, naming 3 mm; on solidcore the kernel's refusal
/// carries a size and the edge it was found for (`SolidError::FilletRefused`), and the message
/// names the edge.
/// the two rounds on each end would cross. Refused, naming 3 mm: the kernel's refusal carries a
/// size and the edge it was found for (`SolidError::FilletRefused`), and the message names the
/// edge.
#[test]
fn a_round_past_a_full_round_is_refused_naming_the_largest_that_fits_and_its_edge() {
let mut s = Session::default();
run(&mut s, "solid.box", json!({"length": 14, "width": 6, "height": 10, "corner": [14, 0, 0]}));
let uprights = json!([[14, 0, 5], [28, 0, 5], [14, 6, 5], [28, 6, 5]]);
let on_solidcore = solidcraft_kernel::kernel_route::backend() == solidcraft_kernel::kernel_route::Backend::Solidcore;
for r in [3.001, 3.5] {
let e = s.execute("solid.fillet", &json!({"edges": uprights, "radius": r})).unwrap_err().to_string();
assert!(e.contains("the largest radius that fits is 3 mm"), "{r}: {e}");
assert!(!on_solidcore || e.contains("allow, at the edge at ("), "{r}: {e}");
assert!(e.contains("allow, at the edge at ("), "{r}: {e}");
assert_eq!(e.matches("that fits is").count(), 1, "{r}: {e}");
}
assert!((volume(&mut s) - 840.0).abs() < 1e-6, "the part stays as it was");