Convert compute_pressure_basic web tests to test_driver
The purpose of this change is start using WebDriver. WebDriver commands
for Compute Pressure are defined in
https://www.w3.org/TR/compute-pressure/#automation
Dedicated workers need to manipulate virtual pressure sources, but
testdriver calls can only be made in the embedded window, so the
existing solution of having '.any.js' files with META: global=window,dedicatedworker
does not work anymore. The solution is
to use message passing so that workers make the embedder window invoke
the virtual pressure source calls and use WPT's variants concept to run
the same test under multiple configurations. Due to this limitation
'.any.js' files needs to be converted to '.window.js'. README.md has
been updated to include a detailed guide for creating tests.
WebDriver endpoints and virtual pressure sources work in Window and
Dedicated Worker scopes, but not shared worker ones: we store virtual
pressure source information in WebContentsUserData, which does not
integrate well with shared workers.
Bug: 347031400
Change-Id: I3cb482c0a689e84012735acd6bc9d33981a7d2f9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5873130
Reviewed-by: Raphael Kubo Da Costa raphael.kubo.da.costa@intel.com
Commit-Queue: Raphael Kubo Da Costa raphael.kubo.da.costa@intel.com
Reviewed-by: Reilly Grant reillyg@chromium.org
Auto-Submit: Juha J Vainio juha.j.vainio@intel.com
Cr-Commit-Position: refs/heads/main@{#1358424}