So I am running a simple enough Selenium program through the GRID. I have Grid and Node all setup working perfectly.
The issue I am having is with the below :
driver.manage().window().setPosition(new Point(X,Y));
This appears to have zero effect on the browser on the node machine. Looking at the server this command is understand and even processed without error :
14:57:02.811 INFO - Done: [set window position]
14:57:11.318 INFO - Executing: [get window position])
Code used was
driver.manage().window().setPosition(new Point(600, 500));
I inserted some code to get the cords of the browser, and they are returned as :
System.out.println(" POSITION " +driver.manage().window().getPosition());
RESULT = "POSITION (600, 500)"
I am using the "import org.openqa.selenium.Point;" import.
There are not other issues with the code.
The reason I need to move the browser , is because a second browser keeps overlapping the first browser , thus making it impossible for Selenium to interact with the first browser (I am using the parallel testing . I resized both browsers to try and fix the issue. Incidentally, there is no issue at all with the resize code (below) that works perfectly :
driver.manage().window().setSize(new Dimension(600, 500));
FULL CODE :
DesiredCapabilities cap = DesiredCapabilities.firefox();
cap.setBrowserName("firefox");
driver = new RemoteWebDriver(new URL(Node), cap);
// Puts an Implicit wait, Will wait for 10 seconds before throwing
driver.manage().timeouts().implicitlyWait(20, TimeUnit.SECONDS);
// Launch website
driver.navigate().to(URL);
driver.manage().window().setSize(new Dimension(600, 500));
driver.manage().window().setPosition(new Point(600, 500));