From 660c4de145ce8dd7b304bf636805d18a1cecc944 Mon Sep 17 00:00:00 2001 From: Jeremy Rose Date: Fri, 15 Aug 2025 15:47:55 -0700 Subject: [PATCH] clippy --- codex-rs/tui/src/history_cell.rs | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/codex-rs/tui/src/history_cell.rs b/codex-rs/tui/src/history_cell.rs index 2e8e189841..1d7f7db266 100644 --- a/codex-rs/tui/src/history_cell.rs +++ b/codex-rs/tui/src/history_cell.rs @@ -917,22 +917,6 @@ fn format_mcp_invocation<'a>(invocation: McpInvocation) -> Line<'a> { Line::from(invocation_spans) } -#[cfg(test)] -mod tests { - use super::*; - - #[test] - fn parsed_command_with_newlines_starts_each_line_at_origin() { - let parsed = vec![ParsedCommand::Unknown { - cmd: "printf 'foo\nbar'".to_string(), - }]; - let lines = exec_command_lines(&[], &parsed, None, None); - assert!(lines.len() >= 3); - assert_eq!(lines[1].spans[0].content, " └ "); - assert_eq!(lines[2].spans[0].content, " "); - } -} - pub(crate) fn new_exec_approval_decision( approval_request: &ApprovalRequest, decision: codex_core::protocol::ReviewDecision, @@ -1020,3 +1004,19 @@ pub(crate) fn new_reasoning_block( lines.push(Line::from("")); TranscriptOnlyHistoryCell { lines } } + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn parsed_command_with_newlines_starts_each_line_at_origin() { + let parsed = vec![ParsedCommand::Unknown { + cmd: "printf 'foo\nbar'".to_string(), + }]; + let lines = exec_command_lines(&[], &parsed, None, None); + assert!(lines.len() >= 3); + assert_eq!(lines[1].spans[0].content, " └ "); + assert_eq!(lines[2].spans[0].content, " "); + } +}