From abd0365c16ab2e65773f4c8d3b782c2e44128dc5 Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Sat, 13 Jun 2026 20:45:15 +0200 Subject: chore(treewide): Remove glob imports --- crates/turtle/src/command/client/daemon.rs | 4 +++- crates/turtle/src/command/client/history.rs | 4 +++- crates/turtle/src/command/client/search/cursor.rs | 7 +++---- crates/turtle/src/command/client/search/inspector.rs | 5 ++++- crates/turtle/src/command/client/search/keybindings/actions.rs | 2 +- crates/turtle/src/command/client/search/keybindings/conditions.rs | 2 +- crates/turtle/src/command/client/search/keybindings/key.rs | 2 +- crates/turtle/src/command/client/search/keybindings/keymap.rs | 2 +- 8 files changed, 17 insertions(+), 11 deletions(-) (limited to 'crates/turtle/src/command/client') diff --git a/crates/turtle/src/command/client/daemon.rs b/crates/turtle/src/command/client/daemon.rs index 30b478ec..39aa1b1e 100644 --- a/crates/turtle/src/command/client/daemon.rs +++ b/crates/turtle/src/command/client/daemon.rs @@ -548,7 +548,9 @@ fn kill_process(pid: u32) { #[cfg(test)] mod tests { - use super::*; + use super::{ + DAEMON_PROTOCOL_VERSION, DAEMON_VERSION, daemon_matches_expected, daemon_mismatch_message, + }; #[test] fn test_version_matches() { diff --git a/crates/turtle/src/command/client/history.rs b/crates/turtle/src/command/client/history.rs index fde73449..9f383a08 100644 --- a/crates/turtle/src/command/client/history.rs +++ b/crates/turtle/src/command/client/history.rs @@ -1043,7 +1043,9 @@ impl Cmd { mod tests { use time::macros::datetime; - use super::*; + use super::{ + History, Settings, TailEvent, TailKind, Timezone, normalize_command_for_storage, parse_fmt, + }; #[test] fn normalize_command_strips_trailing_spaces_and_tabs() { diff --git a/crates/turtle/src/command/client/search/cursor.rs b/crates/turtle/src/command/client/search/cursor.rs index a69f1359..e13e52b3 100644 --- a/crates/turtle/src/command/client/search/cursor.rs +++ b/crates/turtle/src/command/client/search/cursor.rs @@ -279,15 +279,14 @@ impl Cursor { #[cfg(test)] mod cursor_tests { - use super::Cursor; - use super::*; + use super::{Cursor, WordJumpMode, WordJumper}; - static EMACS_WORD_JUMPER: WordJumper = WordJumper { + static EMACS_WORD_JUMPER: WordJumper<'_> = WordJumper { word_chars: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", word_jump_mode: WordJumpMode::Emacs, }; - static SUBL_WORD_JUMPER: WordJumper = WordJumper { + static SUBL_WORD_JUMPER: WordJumper<'_> = WordJumper { word_chars: "./\\()\"'-:,.;<>~!@#$%^&*|+=[]{}`~?", word_jump_mode: WordJumpMode::Subl, }; diff --git a/crates/turtle/src/command/client/search/inspector.rs b/crates/turtle/src/command/client/search/inspector.rs index 6c2c59fe..186dcd3a 100644 --- a/crates/turtle/src/command/client/search/inspector.rs +++ b/crates/turtle/src/command/client/search/inspector.rs @@ -334,7 +334,10 @@ pub(crate) fn draw_full( mod tests { use super::draw_ultracompact; use crate::atuin_client::history::{History, HistoryId, HistoryStats}; - use ratatui::{backend::TestBackend, prelude::*}; + use ratatui::{ + backend::TestBackend, + prelude::{Line, Rect, Terminal}, + }; use time::OffsetDateTime; fn mock_history_stats() -> (History, HistoryStats) { diff --git a/crates/turtle/src/command/client/search/keybindings/actions.rs b/crates/turtle/src/command/client/search/keybindings/actions.rs index e9b654c5..2842d618 100644 --- a/crates/turtle/src/command/client/search/keybindings/actions.rs +++ b/crates/turtle/src/command/client/search/keybindings/actions.rs @@ -242,7 +242,7 @@ impl<'de> Deserialize<'de> for Action { #[cfg(test)] mod tests { - use super::*; + use super::Action; #[test] fn parse_basic_actions() { diff --git a/crates/turtle/src/command/client/search/keybindings/conditions.rs b/crates/turtle/src/command/client/search/keybindings/conditions.rs index e52e4864..fd993f2b 100644 --- a/crates/turtle/src/command/client/search/keybindings/conditions.rs +++ b/crates/turtle/src/command/client/search/keybindings/conditions.rs @@ -373,7 +373,7 @@ impl<'de> Deserialize<'de> for ConditionExpr { #[cfg(test)] mod tests { - use super::*; + use super::{ConditionAtom, ConditionExpr, EvalContext}; fn ctx( cursor: usize, diff --git a/crates/turtle/src/command/client/search/keybindings/key.rs b/crates/turtle/src/command/client/search/keybindings/key.rs index 841656d2..5e772238 100644 --- a/crates/turtle/src/command/client/search/keybindings/key.rs +++ b/crates/turtle/src/command/client/search/keybindings/key.rs @@ -315,7 +315,7 @@ impl<'de> Deserialize<'de> for KeyInput { #[cfg(test)] mod tests { - use super::*; + use super::{KeyCodeValue, KeyInput, SingleKey}; use ratatui::crossterm::event::{KeyCode, KeyEvent, KeyModifiers}; #[test] diff --git a/crates/turtle/src/command/client/search/keybindings/keymap.rs b/crates/turtle/src/command/client/search/keybindings/keymap.rs index 00678b20..067d9403 100644 --- a/crates/turtle/src/command/client/search/keybindings/keymap.rs +++ b/crates/turtle/src/command/client/search/keybindings/keymap.rs @@ -117,7 +117,7 @@ impl Default for Keymap { #[cfg(test)] mod tests { use super::super::conditions::ConditionAtom; - use super::*; + use super::{Action, EvalContext, KeyInput, KeyRule, Keymap, SingleKey}; fn make_ctx(cursor: usize, width: usize, selected: usize, len: usize) -> EvalContext { EvalContext { -- cgit v1.3.1