Eggplant Functional: Automatically Run Selenium Standalone Server on Windows

To fully automate the execution of Selenium WebDriver tests through Eggplant Functional, it’s convenient to set up the Selenium Standalone Server to run automatically every time the system under test boots. If the Standalone Server isn't running, the test will not execute, leading to delays in continuous integration, and false-negatives on regression testing.

Option A: From the Testplant WebDriver installation package, copy the file called RunSeleniumServer.bat to the Startup folder.

Depending on your operating system, the Startup folder may be located at:

Option B: To manually create a batch file for a Selenium Standalone Server installation

  1. Create a file and type the following line into the file:
    set JAVA_HOME = “<C:\program files\path\to\java="">\bin” “%JAVA_HOME%\java” -jar C:\Path\To\Selenium\selenium-server-standalone-3.6.0.jar
  2. Be sure that the version number for the jar file matches the one that you have installed
  3. Save the file to the Startup folder and name it RunSeleniumServer.bat. Depending on your operating system, the Startup folder may be located at:
    • C:\Users\Username\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup (Windows 8/10)
    • C:\Documents and Settings\UserName\Start Menu\Programs\Startup (Earlier Windows)

Now every time the machine restarts, the batch file will run, launching the Selenium Standalone Server. For more details, see our documentation on the Selenium WebDriver integration.