testCursorPreservedOnListCreation() {
    setUpListAndBlockquoteTests();
    FIELDMOCK.getPluginByClassId('Bidi').$anyTimes().$returns(null);
    FIELDMOCK.queryCommandValue(Command.DEFAULT_TAG)
        .$anyTimes()
        .$returns(TagName.P);

    FIELDMOCK.$replay();
    let cursorPlaceholder = dom.getElement('cursorRoot');
    Range.createCaret(cursorPlaceholder.firstChild, 3).select();

    FORMATTER.execCommandInternal(BasicTextFormatter.COMMAND.UNORDERED_LIST);
    const selection = window.getSelection();
    assertTrue(selection.isCollapsed);
    assertEquals(selection.rangeCount, 1);

    const li = dom.getElementByTagNameAndClass(
        TagName.LI, null, dom.getElement('cursorTest'));
    if (userAgent.WEBKIT) {
      assertEquals(selection.anchorNode, li.firstChild);
      assertEquals(selection.anchorOffset, 3);
    } else {
      // IE adds extra div inside LI and uses it as the anchorNode
      assertEquals(selection.anchorNode, userAgent.GECKO ? li : li.firstChild);
      assertEquals(selection.anchorNode.innerText, 'abc123');
      assertEquals(selection.anchorNode.childNodes.length, 2);
      assertEquals(selection.anchorOffset, 1);
    }

    tearDownListAndBlockquoteTests();
  }
@suppress {missingProperties, visibility} suppression added to enable type
checking