void () { @Language("JAVA") @NonNls String text = """ public class Test { public void test() { int i = 1; } }"""; init(text, PlainTextFileType.INSTANCE); addBookmark(2); Document document = getEditor().getDocument(); getEditor().getSelectionModel().setSelection(document.getLineStartOffset(2) - 1, document.getLineEndOffset(2)); delete(); assertTrue(getManager().getBookmarks().isEmpty()); }