;
}

::view-transition {
  background: pink;
}
</style>

<div id=target class="parent named"><div class=child></div></div>

<script>
failIfNot(document.startViewTransition, "Missing document.startViewTransition");

function runTest() {
  let transition = document.startViewTransition();
  transition.ready.then(() => {
    requestAnimationFrame(() => {
      target.classList.remove("named");
    });
  });
  transition.finished.then(takeScreenshot);
}

onload = () => requestAnimationFrame(() => requestAnimatio