Resolves the agent from CLI flag or resolved config. Priority: CLI flag > resolved config agent (which already handles config layer merging).
(cli_agent: Option<String>, resolved_config: &ResolvedConfig)
| 773 | /// |
| 774 | /// Priority: CLI flag > resolved config agent (which already handles config layer merging). |
| 775 | pub fn resolve_agent(cli_agent: Option<String>, resolved_config: &ResolvedConfig) -> String { |
| 776 | cli_agent.unwrap_or_else(|| resolved_config.agent.clone()) |
| 777 | } |
| 778 | |
| 779 | #[cfg(test)] |
| 780 | mod tests { |