void () { final ConsoleViewImpl console = myConsole; final Editor editor = console.getEditor(); console.print("xxxx", ConsoleViewContentType.NORMAL_OUTPUT); console.print("a", ConsoleViewContentType.USER_INPUT); console.print("b", ConsoleViewContentType.USER_INPUT); console.print("c", ConsoleViewContentType.USER_INPUT); console.print("d", ConsoleViewContentType.USER_INPUT); console.flushDeferredText(); assertEquals("xxxxabcd", editor.getDocument().getText()); backspace(console); assertEquals("xxxxabc", editor.getDocument().getText()); backspace(console); assertEquals("xxxxab", editor.getDocument().getText()); backspace(console); assertEquals("xxxxa", editor.getDocument().getText()); backspace(console); assertEquals("xxxx", editor.getDocument().getText()); }