chromium/content/test/data/accessibility/html/replace-data.html

<!--
@WAIT-FOR:bananas
@BLINK-DENY:nameFrom*
-->
<!DOCTYPE html>
<html>
<body>
  <p id="text1">oranges</label>
  <p id="text2"><span><span>grapes</span></span></label>
</div>

<script>
  setTimeout(() => {
    const text1 = document.getElementById('text1');
    text1.firstChild.replaceData(0,5, 'appl'); // oranges -> apples

    const text2 = document.getElementById('text2');
    var text2data = text2.firstElementChild.firstElementChild.firstChild;
    text2data.replaceData(0, 5, 'banana');  // grapes -> bananas
  }, 100);
</script>
</body>
</html>