feat: Tambah field pending_clipboard_copy di MiscState
This commit is contained in:
@@ -400,6 +400,7 @@ pub struct MiscState {
|
||||
pub tick_count: u64,
|
||||
pub todo_content: String,
|
||||
pub lesson_running: bool,
|
||||
pub pending_clipboard_copy: Option<String>,
|
||||
}
|
||||
|
||||
impl MiscState {
|
||||
@@ -419,6 +420,7 @@ impl MiscState {
|
||||
tick_count: 0,
|
||||
todo_content: String::new(),
|
||||
lesson_running: false,
|
||||
pending_clipboard_copy: None,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -493,4 +495,10 @@ mod tests {
|
||||
assert_eq!(input.buffer, "/model");
|
||||
assert_eq!(input.cursor, "/model".len());
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn misc_state_starts_with_no_pending_clipboard_copy() {
|
||||
let misc = MiscState::new();
|
||||
assert!(misc.pending_clipboard_copy.is_none());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user