ncbi / robotframework-pageobjects

Implementation of the Page Object pattern with Robot Framework and selenium. Also facilitates page object pattern independent of Robot Framework
http://ncbi.github.io/robotframework-pageobjects
Other
84 stars 75 forks source link

Open browser as maximized instead of 1920x1080 #39

Closed s4int closed 9 years ago

s4int commented 9 years ago

I had some problems running robot with page objects on Xvfb, my default resolution is 1280x1024. - As a result screenshots were cropped.

My proposition is to change self.set_window_size(1920, 1080) to: self.maximize_browser_window()

On line: https://github.com/ncbi/robotframework-pageobjects/blob/master/robotpageobjects/page.py#L594

If someone wants to use different resolution that his desktop or grid resolution than he should explicitly set it in test setup with "Set Window Size" keyword.

kahunacohen commented 9 years ago

Not sure of the implications of this. There's a reason we maximize, but I don't remember why. @hellmanj ?

hellmanj commented 9 years ago

I think we were having trouble with element visibility in phantomjs because the default window size is so small. But @s4int is probably right that it's not this package's job to solve that problem.

kahunacohen commented 9 years ago

Why not leave the browser open as default and leave it to the user. In our base page object at NCBI we can maximize if we want. Is that a possibility @hellmanj ? Will that break any of our tests for RFPO?

hellmanj commented 9 years ago

That's what was suggested and I'm saying I agree, I'll give it a try.