webdriver icon indicating copy to clipboard operation
webdriver copied to clipboard

Expose an API to emulate device resolution (devicePixelRatio)

Open noamr opened this issue 5 years ago • 2 comments

Continuing the discussion in https://github.com/w3c/webdriver/issues/1378#issuecomment-673356461 This came up from trying to create web platform tests that take srcset into account.

All browser engines today contain an option to emulate devicePixelRatio. Several web features rely on this - for example, responsive images. However, there is no cross-browser API to emulate this value for the purpose of testing.

Suggesting that this would be a parameter when creating a window, or an additional POST (similar to /rect)

noamr avatar Sep 22 '20 09:09 noamr

I wonder if we should reserve this for webdriver-bidi only. Or how do we handle feature requests like that for the HTTP-based webdriver protocol? @jgraham?

whimboo avatar Sep 24 '20 09:09 whimboo