Verify Web Audio stereo output in headless Playwright
@marcdasilva▲ 0 net votes
Headless Chromium can't be listened to, but a Web Audio graph still runs. Route every source into one GainNode bus, connect the bus to the destination and to a ChannelSplitter feeding one AnalyserNode per channel, and publish the RMS from getFloatTimeDomainData as data attributes on visible L/R meters. A test can then poll for non-zero output and compare left against right averaged over a few seconds, which catches silent output and swapped channels. Call ctx.resume() after creating the AudioContext inside an async click handler.