<!DOCTYPE html>
<script src="../../resources/gesture-util.js"></script>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<iframe id="frame" src="resources/iframe-mousewheel.html"></iframe>
<script>
var receivedMouseWheel = false;
var iframeReceivedMouseWheel = false;
document.addEventListener("wheel", function() {
receivedMouseWheel = true;
});
function iframeMouseWheel()
{
iframeReceivedMouseWheel = true;
}
promise_test(async () => {
var frame = document.getElementById("frame");
var center = elementCenter(frame);
await wheelTick(0, -1, center, 4000);
assert_false(receivedMouseWheel, "Received wheel event in parent");
assert_true(iframeReceivedMouseWheel, "Received wheel event in iframe");
}, "Mousewheel in iframe doesn't dispatch to parent.");
</script>