
    margin:  0;
  }
  .snap {
    scroll-snap-align: center;
    height: 100vh;
    margin:  0;
  }
</style>
<body onload = "runTest()">
<div id = "card1" class="snap">ONE</div>
<div id = "card2" class="snap">TWO</div>
<div id = "card3" class="snap">THREE</div>
</body>
<script type="text/javascript">
  function runTest() {
    promise_test(async t => {
      const scroller = document.scrollingElement;
      // scroll to card THREE
      let expectedSnapPosition = card3.offsetTop;
      scroller.scrollTo(0,