Lighthouse does not get cookies on WebPageTest run

When doing a WebPageTest run for a website which is behind a cookie for a new version, I see that WebPageTest results are accurate but the Lighthouse numbers are not.

On digging deeper, saw that the assets being loaded on Lighthouse run were incorrect, meaning the cookies were not being forwarded from WebpageTest to Lighthouse.

Using Scripting to pass cookies. Can someone help with this please?

Hey Adarsh!

Yeah, the Lighthouse testing is handed off entirely to Lighthouse, which means that WebPageTest scripting commands and things like cookies don’t get applied at the moment to those tests.

2 Likes

Thanks, Tim! Any plans to support this in future?

Nothing explicit on the roadmap, though I do see an old issue (and old PR?) for this. Likely needs to be dusted off though before it’s ready to go. lighthouse for current browser session by imkalvin · Pull Request #420 · WPO-Foundation/wptagent · GitHub