Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Selenium Grid +Error forwarding the new session Empty pool of VM for setup Capabilities

I am trying a POC on selenium grid. I am receiving this error :

Error forwarding the new session Empty pool of VM for setup Capabilities [{browserName=chrome, version=47, platform=WIN8_1}]

Below is the code :

BeforeTest
    public void setup() throws MalformedURLException{
        nodeURL="http://localhost:4444/wd/hub";
        DesiredCapabilities capabilities = DesiredCapabilities.chrome();
        capabilities.setBrowserName("chrome");
        capabilities.setVersion("47");
        capabilities.setPlatform(Platform.WIN8_1);
        extent = new ExtentReports("./extentReport.html",true,DisplayOrder.NEWEST_FIRST);
        System.setProperty("webdriver.chrome.driver", "<path>\\chromedriver.exe");
        driver = new RemoteWebDriver(new URL(nodeURL),capabilities);
        //driver = new ChromeDriver(capabilities);
        driver.manage().window().maximize();
        driver.get("http://www.qaonlinetraining.com");
    }
like image 355
Abhinav Avatar asked Dec 11 '15 06:12

Abhinav


1 Answers

I just did a small tweak.

1). I launched the command prompt in "admin mode". 2). Gave the java path as "cd C:\Program Files (x86)\Java" in it 3). Then ran the command as "java -jar selenium-server-standalone-3.0.1.jar" without specifying any role

and Vollaaaa...it got fixed...!!!

Thanks to all of you for your help...Was after this error for last 3 days...a great relief must say.. :-)

Checkout this link for more information on how to do this... https://stackoverflow.com/a/42187314/7551276

like image 199
Varun Gautam Avatar answered Jan 02 '23 22:01

Varun Gautam