generated-scene: add command-center automation semantics
This commit is contained in:
@@ -279,6 +279,58 @@ fn fee_control_materialization_emits_timeout_contract_in_generated_artifacts() {
|
||||
assert!(detect_script.contains("statusOnTimeout"));
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn command_center_workflow_ir_includes_automation_semantics() {
|
||||
let root = temp_workspace("sgclaw-command-center-automation-semantics");
|
||||
let skill_root = generate_scheduled_monitoring_action_skill_package(
|
||||
GenerateScheduledMonitoringActionSkillRequest {
|
||||
scene_id: "command-center-fee-control-monitor".to_string(),
|
||||
scene_name: "command-center-fee-control-monitor".to_string(),
|
||||
output_root: root.clone(),
|
||||
source_evidence_json: PathBuf::from(
|
||||
"tests/fixtures/generated_scene/monitoring_action_source_evidence_extraction_2026-04-21.json",
|
||||
),
|
||||
ir_contract_json: PathBuf::from(
|
||||
"tests/fixtures/generated_scene/scheduled_monitoring_action_ir_contract_2026-04-22.json",
|
||||
),
|
||||
trigger_contract_json: PathBuf::from(
|
||||
"tests/fixtures/generated_scene/scheduled_monitoring_action_trigger_runtime_contract_2026-04-22.json",
|
||||
),
|
||||
},
|
||||
)
|
||||
.unwrap();
|
||||
|
||||
let workflow_ir: Value = serde_json::from_str(
|
||||
&fs::read_to_string(skill_root.join("references/workflow-ir.json")).unwrap(),
|
||||
)
|
||||
.unwrap();
|
||||
|
||||
assert!(
|
||||
workflow_ir.get("actionContracts").is_some(),
|
||||
"workflow-ir.json must include actionContracts"
|
||||
);
|
||||
assert!(
|
||||
workflow_ir.get("iterationContract").is_some(),
|
||||
"workflow-ir.json must include iterationContract"
|
||||
);
|
||||
assert!(
|
||||
workflow_ir.get("executionFlow").is_some(),
|
||||
"workflow-ir.json must include executionFlow"
|
||||
);
|
||||
assert!(
|
||||
workflow_ir.get("resultStateMachines").is_some(),
|
||||
"workflow-ir.json must include resultStateMachines"
|
||||
);
|
||||
assert!(
|
||||
workflow_ir.get("queueTransitionRules").is_some(),
|
||||
"workflow-ir.json must include queueTransitionRules"
|
||||
);
|
||||
assert!(
|
||||
workflow_ir.get("logWriteContracts").is_some(),
|
||||
"workflow-ir.json must include logWriteContracts"
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn available_balance_and_archive_materialization_emit_explicit_dependency_classification_in_references() {
|
||||
let example_output = Command::new("cargo")
|
||||
|
||||
Reference in New Issue
Block a user