Open MaryamHuntsperger opened 3 months ago
Tagging @mjkozicki , @claud-io , would appreciate if you could review this PR and provide feedback. This should be a useful command to run true interactivity tests with Event timing metrics.
@pmeenan / @vibaldem FYI, this PR is for https://github.com/catchpoint/WebPageTest/issues/3048 and https://github.com/catchpoint/WebPageTest/issues/3049 .
@pmeenan, please take a look.
Existing click and clickAndWait WPT commands are JavaScript initiated events which are synthetic. Hence "Trusted" flag for JS events is set to false. Such events get ignored by EventTiming API (https://www.w3.org/TR/event-timing/). This problem was issued https://github.com/catchpoint/WebPageTest/issues/3048
Moreover, WPT click command does not support right and double click; mentioned in https://github.com/catchpoint/WebPageTest/issues/3049 .
We have created a new mouseClick command with the following format which supports left, right and double click: mouseClick [tab] Id| selector [tab] left|right|double
The new command uses Devtools Protocol (https://chromedevtools.github.io/devtools-protocol/tot/Input/) input domain to dispatch Trusted mousepressed and mousereleased events.