feat(aura-cli): de-prefix input-role markers ([in:price] -> [price])

Symmetric with the output de-prefix shipped in 2f49165: the composite
definition render now shows input roles as bare [<name>] markers, matching
the [<name>] outputs. One-token change in render_definition's input-role
loop (format!("in:{}", role.name) -> role.name.clone()); the two render
doc comments + the blueprint_view_golden / needle / MACD-render asserts
updated. Render-only; compiled_view_golden byte-identical; aura run --macd
unchanged.

refs #41
This commit is contained in:
2026-06-08 10:51:50 +02:00
parent efbe0f4a66
commit 32ac8a30ea
2 changed files with 6 additions and 6 deletions
+3 -3
View File
@@ -391,7 +391,7 @@ mod tests {
let out = graph::render_blueprint(&sample_blueprint());
// the sma_cross body is defined exactly once, with its interior + ports
assert_eq!(out.matches("sma_cross(").count(), 1, "definition not rendered once:\n{out}");
for needle in ["[SMA]", "[Sub(#A,#B)]", "[in:price]", "[cross]"] {
for needle in ["[SMA]", "[Sub(#A,#B)]", "[price]", "[cross]"] {
assert!(out.contains(needle), "missing {needle} in definition:\n{out}");
}
}
@@ -504,7 +504,7 @@ mod tests {
where:
sma_cross() -> (cross):
[in:price]
[price]
┌───└───┐
↓ ↓
[SMA] [SMA]
@@ -587,7 +587,7 @@ sma_cross() -> (cross):
assert!(out.contains("[EMA(slow)]"), "slow EMA folds its param: {out}");
assert!(out.contains("[EMA(signal)]"), "signal EMA folds its param: {out}");
assert!(out.contains("[Sub(#A,#B)]"), "Sub shows its two ordered inputs: {out}");
assert!(out.contains("[in:price]"), "named MACD input role: {out}");
assert!(out.contains("[price]"), "named MACD input role: {out}");
assert!(!out.contains("[param:"), "param marker nodes removed: {out}");
assert!(!out.contains("[out:"), "output prefix dropped: {out}");
}