PMC:QA:Hudson with selenium
Contents
hudson with selenium
Configuring the Seleniumhq Plugin
first start hudson and create a new project,eg:Selenium
Global config
Configure Seleniumhq test runner (selenium-server.jar path) [via Manage Hudson -> Configure System]
example:
Job config
seleniumhq plugin:This plugin allows you to run and load HTML Selenese suite result generate by Selenium Server from Seleniumhq. Hudson will generate the trend report of test result.
The Seleniumhq plug in can be downloaded here[1].
1.Install the selenium plugin [via Manage Hudson -> Manage Plugins]
select "Hudson Seleniumhq plugin",then click install button,restart hudson
2. Configure your project's build script to generate Seleniumhq HTML reports (See below for examples with Ant Command, batch Command and Hudson build step) 3. Enable the "Publish Selenium Report" publisher 4. Specify the test file to load
example:
Configuring build tools
Here are the configuration details for common build tools. Please feel free to update this with corrections or additions.
Build Step in hudson
You can lauch the HTML Selenese suite with selenium-server with the buid step provide by this plugin. This step make exactly the same as Batch command (See below) but the plugin offer ther possibily to enter an PATH or an URL for the suiteFile param.
1. Add a build step (SeleniumHQ htmlSuite Run) in your job configure page
2. Field the mandatory field
example:
Note:you need to make the report file point to the path of project's workspace.
HTMLSuite.html
Batch command
1. Add a build step in your job configure page.
2. Add command to lauch HTML Selenese suite with selenium-server
example:
Ant
We've also provided an Ant task to make it easier to launch the tests. Run it like this: Seleniumhq doc
example:
build.xml
Test Results
build this project
results
it will open a Firefox page and search "Selenium OpenQ" ...
Report
click "Selenium Report" to review test report
Reference
Links
- Go back to PMC:QA