void () { init("line1<caret>\nline2\nline3", PlainTextFileType.INSTANCE); addCollapsedFoldRegion(5, 7, "..."); executeAction(IdeActions.ACTION_EDITOR_MOVE_CARET_RIGHT); assertEquals(new VisualPosition(0, 6), getEditor().getCaretModel().getVisualPosition()); }