I am facing an issue with Maximize Browser Window keyword. While running in local this keyword works fine and able to maximize the browser window.
But while tests in remote machine its not maximizing the browser window. In VM browser is getting run with 1024 x 768 screen resolution.
Due to this many test cases are failing as many of the screen elements are not visible in this resolution.
Thanks for the input.
I was expecting Maximize Browser Window keyword to auto handle this explicitly. Is it not the case?
Is this keyword maximizes the browser to the resolution which is already specified in the system display settings?
Set Window Size seems to be working. But still i have to find the perfect resolution manually for this and add at test case level.
The browser sends the maximise window command to the desktop (window manager on Linux) the OS resizes the window frame and the browser adjusts to the new size. Linux is a bit different to windows in that the desktop is made up of different optional components being the display manager (X11 or Wayland), the window manager (Gnome, KDE, etc) and a few other components. You can run an application from a terminal without a window manager, but there are no window frames and the window can’t be resized. In Windows its all one process, Macos is BSD based so it’s like Linux (and other Unixes) except there is only 1 window manager and so it’s always there
Yes it will maximise the window to whatever the screen resolution is but depending on the settings probably a little smaller, e.g. if your remote machine is Windows XP with a screen resolution of 800x600 the windows would end up being about 800x550 as the start menu takes some of the bottom of the screen unless it’s configured for auto-hide or allow applications to overlap.
Glad you got a solution
A little tip: Open the page in Chrome, open dev tools and then resize the window, Chrome will show the window size just under the hamburger menu when dev tools is open, I haven’t seen other browsers do that but ones based on chromium may.
I have the same issue but I’m using Selenium via Robot Framework, I’ve tried various keywords like Set Window Size etc…but it keeps maxing out at 1040x784 even when I try and set them manually and use the max size keywords…really stumped with it.
Starting to think its more to do with backend settings where Selenium is hosted on of which I’m unsure as any script changes doesn’t seem to make a difference yet. all the above stuff on this thread hasn’t resolved it yet for me, so this is a last hope!