chromium/third_party/blink/web_tests/editing/undo/undo-indent.html

<!doctype html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../assert_selection.js"></script>
<div id="log"></div>
<script>
test(() => {
    assert_selection(
        '<ol contenteditable><li>one</li><li>two</li><li>^three|</li><ol><li>four</li></ol></ol>',
        selection => {
            selection.document.execCommand('Indent');
            selection.document.execCommand('Undo');
        },
        '<ol contenteditable><li>one</li><li>two</li><li>^three|</li><ol><li>four</li></ol></ol>');

    assert_selection(
        '<ol contenteditable><li>one</li><li>two</li><li>^three|</li><ol><li>four</li></ol></ol>',
        selection => {
            selection.document.execCommand('Indent');
            selection.document.querySelector('ol').contentEditable = false;
            selection.document.execCommand('Undo');
        },
        '<ol contenteditable=\"false\"><li>one</li><li>two</li><ol><li>^three|</li><li>four</li></ol></ol>',
        'Undo does nothing for uneditable');
});
</script>