···55555656 await (testType === 'userEvent' ? userEvent.wheel(selector, options) : selector.wheel(options))
57575858- expect(wheel).toHaveBeenCalledOnce()
5858+ // the wheel event is dispatched asynchronously in the browser, so poll for
5959+ // it instead of asserting synchronously (matches the default-delta case above)
6060+ await expect.poll(() => wheel).toHaveBeenCalledOnce()
5961 expect(wheel.mock.calls[0][0].deltaX).toBe(deltaX)
6062 expect(wheel.mock.calls[0][0].deltaY).toBe(deltaY)
6163 })