Skip to content

Commit 5401642

Browse files
committed
style: apply cargo fmt formatting
1 parent 6553902 commit 5401642

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

src/commands/mod.rs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ use crate::domain::{
66
ReviewSource, ReviewStatus, ReviewTask, RuleScope,
77
};
88
use crate::infra::acp::{
9-
GenerateTasksInput, ProgressEvent, RunContext, generate_tasks_with_acp,
10-
invalidate_agent_cache, list_agent_candidates,
9+
GenerateTasksInput, ProgressEvent, RunContext, generate_tasks_with_acp, invalidate_agent_cache,
10+
list_agent_candidates,
1111
};
1212
use crate::infra::diff::index::DiffIndex;
1313
use crate::infra::hash::hash_diff;
@@ -1265,11 +1265,8 @@ pub async fn fetch_remote_pr(
12651265
pub async fn get_agents(_state: State<'_, AppState>) -> Result<Vec<AgentInfo>, String> {
12661266
let candidates = crate::infra::acp::list_agent_candidates();
12671267
let config = crate::infra::app_config::load_config();
1268-
let custom_ids: std::collections::HashSet<&str> = config
1269-
.custom_agents
1270-
.iter()
1271-
.map(|c| c.id.as_str())
1272-
.collect();
1268+
let custom_ids: std::collections::HashSet<&str> =
1269+
config.custom_agents.iter().map(|c| c.id.as_str()).collect();
12731270

12741271
let agents: Vec<AgentInfo> = candidates
12751272
.into_iter()

src/infra/acp/agent_discovery.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,10 @@ mod tests {
267267
let custom = candidates.iter().find(|c| c.id == "custom-bin-test");
268268
assert!(custom.is_some());
269269
let custom = custom.unwrap();
270-
assert!(custom.available, "custom agent with 'ls' command should be available");
270+
assert!(
271+
custom.available,
272+
"custom agent with 'ls' command should be available"
273+
);
271274
// find_bin should resolve to full path or keep original if resolvable
272275
assert!(custom.command.is_some());
273276

@@ -281,7 +284,10 @@ mod tests {
281284
let _guard = CONFIG_MUTEX.lock().unwrap();
282285
let mut config = load_config();
283286
let mut env_vars = std::collections::HashMap::new();
284-
env_vars.insert("LAREVIEW_TEST_CUSTOM_ENV".to_string(), "test_value_123".to_string());
287+
env_vars.insert(
288+
"LAREVIEW_TEST_CUSTOM_ENV".to_string(),
289+
"test_value_123".to_string(),
290+
);
285291

286292
config.custom_agents.push(CustomAgentConfig {
287293
id: "custom-env-test".into(),

0 commit comments

Comments
 (0)