SeleniumRC Plugin

Skip to end of metadata
Go to start of metadata

Plugin Information

Plugin ID seleniumrc-plugin Changes In Latest Release
Since Latest Release
Latest Release
Latest Release Date
Required Core
Dependencies
1.0
Mar 02, 2011
1.366
Source Code
Issue Tracking
Maintainer(s)
Subversion
Open Issues
Nikita Zhelyakov (id: nzhelyakov)
Usage Installations 2013-Apr 627
2013-May 646
2013-Jun 623
2013-Jul 667
2013-Aug 631
2013-Sep 627
2013-Oct 658
2013-Nov 655
2013-Dec 643
2014-Jan 663
2014-Feb 654
2014-Mar 659

This plugin allows you to create Selenium server instance for each project build.

Hudson 1.366 or later.
This plugin was created for Hudson 1.366. It might not work with earlier versions of Hudson.

User guide

We want to run several Selenium tests during build. Our tests have dependencies between themselves. That's why we can't run them in parallel. So we need unique Selenium server for each build. We have the following idea

1. First, you need to configure Selenium manager. Download and extract the archive. There is configuration file settings.xml. You need to add information about your virtual machines there. Manager can work with Windows and Linux machines.

Manager connects to Windows machine using RDP. So if you are using virtual machines with Windows you need to set up Selenium manager on Windows machine. Selenium manager uses RdpConfigs\template.rdp for creating RDP session. You should add credentials to this file using "mstsc" program. After that you may run Selenium manager by using "java -jar selenium_manager-1.0.0-jar-with-dependencies" command.

Manager connects to Linux machine using SSH (j2ssh-core ver. 0.2.9). Selenium server needs X session (DISPLAY variable). So, you need to install Xvfb on Linux machines.

2. Than you need to configure Remote agent. For Windows you should use the directory specified in settings.xml. For Linux you should use user's home folder. In this directory place remote_agent-1.0.0-jar-with-dependencies.jar, selenium-server.jar. Create folder "template" for Firefox profile template. If you don't have any template leave this directory empty. Example

3. After that you need to configure your project. Select "Create Selenium RC instance" in project build environment. "Host" and "Port" fields indicate Selenium manager instance. "Choose operating system" field indicates the type of operating system. Only Windows and Linux are available. "Browser" field indicates the type of browser which you need for your tests. For example, iexploreor or firefox. You may add other browsers to your settings.xml file. After that you may use them in SeleniumRC plugin. In your build scripts you should use variable called "selenium". Example

4. Run your build. Plugin will send browser and OS to Selenium manager. Manager will find node with these browser and OS. After that manager will connect to specified node.

For Windows nodes: manager will open RDP session to selected node. In this session manager will start Remote agent. Agent will start Selenium server using this command:

"java -jar selenium-server.jar -browserSideLog -log selenium.log -multiwindow -port args[1] -firefoxProfileTemplate args[2]", where args[2] = "template" by default.

For Linux nodes: manager will open SSH session to selected node. In this session manager will start Remote agent. Agent will start Xvfb and export DISPLAY variable. After that agent will start Selenium server using this command:

"java -jar selenium-server.jar -browserSideLog -log selenium.log -multiwindow -port args[1] -firefoxProfileTemplate args[2]", where args[2] = "template" by default.

5. As the result you will get a Selenium server instance url or message "Connection failed". Example

or

Changelog

Version 1.0 (March 1, 2011)
  • Initial release.

Labels

Edit
plugin-buildwrapper plugin-buildwrapper Delete
plugin-must-be-labeled plugin-must-be-labeled Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.

Add Comment