MCPcopy Create free account
hub / github.com/TheRedDeveloper/ply-engine / test_backspace_word

Function test_backspace_word

src/text_input.rs:3319–3326  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3317
3318 #[test]
3319 fn test_backspace_word() {
3320 let mut state = TextEditState::default();
3321 state.text = "hello world".to_string();
3322 state.cursor_pos = 11;
3323 state.backspace_word();
3324 assert_eq!(state.text, "hello ");
3325 assert_eq!(state.cursor_pos, 6);
3326 }
3327
3328 #[test]
3329 fn test_delete_word_forward() {

Callers

nothing calls this directly

Calls 1

backspace_wordMethod · 0.80

Tested by

no test coverage detected