<!DOCTYPE html>
<meta charset="utf-8">
<link rel="help" href="https://w3c.github.io/selection-api/#selectionchange-event">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<body>
<input id="input1" value="hello">
<input id="input2" value="world">
<textarea id="textarea1">hello</textarea>
<textarea id="textarea2">world</textarea>
<script>

promise_test(() => {
  return (async function() {
    let selectionChangeCount1 = 0;
    let selectionChangeCount2