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

Function test_backspace

src/text_input.rs:3210–3217  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3208
3209 #[test]
3210 fn test_backspace() {
3211 let mut state = TextEditState::default();
3212 state.text = "Hello".to_string();
3213 state.cursor_pos = 5;
3214 state.backspace();
3215 assert_eq!(state.text, "Hell");
3216 assert_eq!(state.cursor_pos, 4);
3217 }
3218
3219 #[test]
3220 fn test_delete_forward() {

Callers

nothing calls this directly

Calls 1

backspaceMethod · 0.80

Tested by

no test coverage detected