Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

output #14

Open
nicegraham opened this issue May 6, 2013 · 3 comments
Open

output #14

nicegraham opened this issue May 6, 2013 · 3 comments

Comments

@nicegraham
Copy link

Hi,

I was wondering if there's a possibility of outputting the results as a har instead of text?

thanks,
graham

@mariovisic
Copy link
Contributor

It would be possible to grab the timing values and generate a har file using the ruby API. For example you could generate this part of the har file: http://www.softwareishard.com/blog/har-12-spec/#pageTimings

A har file usually has much more information on each request that was performed on the page. It might be possible to pull this information from selenium but I haven't looked into it and wbench doesn't store that information currently.

I'm curious, how do you plan on using the outputted har file? and what information would you want it to contain?

@nicegraham
Copy link
Author

Ideally I'd like to get a complete har of the page loading. We've been using phantomjs to generate the hars, but it has difficulties with some pages. I reckoned chrome / firefox would be more stable. We keep the hars using https://code.google.com/p/harstorage/

I don't know of a way to output a har from selenium directly actually, the closest I know of is to use browsermobproxy but that doesn't give a 100% accurate view of course.

@mariovisic
Copy link
Contributor

That seems like a neat idea, yes I did see this: https://github.com/jarib/browsermob-proxy-rb
That's the only way I could see to generate HAR files using selenium. All of the non ruby examples also involved some kind of proxy as well.
Why aren't your results correct when using the proxy? is it because there is some overhead?

If we did modify wbench to output a HAR files, one problem we'd have is that we'd have to collect a sample HAR file from each loop and then combine the values to get median values; to keep it consistent with what we have currently. This would be problematic for pages where the content isn't always the same; although we could possibly just use the complete median HAR file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants