Giter Club home page Giter Club logo

selenese-runner-java's Introduction

Selenese Runner Java

This is selenese script interpreter implemented by Java.

It supports test-case and test-suite which are Selenium IDE's native format (selenese and side).

Note: Supported Java version is 8 or later.

Build Status

Download

You can download the executable jar from:

https://github.com/vmi/selenese-runner-java/releases

Release Note

4.3.0

  • Catch up Selenium 4.8.1 and update dependency versions.
    • Fix several problems associated with the update.
  • Remove dependency on xalan for security reason. (#337)
  • Run multiple test files in parallel. (PR #340)
    • Add new option --parallel to parallel execution.

Please check RELEASENOTE.md.

Features

  • Run test-case and test-suite generated by Selenium IDE from command line.
  • Supported format:
  • Support commands of Selenium IDE: Flow Control. https://github.com/davehunt/selenium-ide-flowcontrol
  • Log URL/title/Cookies at all commands.
  • Take screenshots at all commands. (optional)
  • Override base URL.
  • Override directory of screenshot path.
  • Generate JUnit XML result.
  • Generate HTML result.

Usage

java -jar selenese-runner.jar <option> ... <test-case|test-suite> ...

 --config (-c) <file>                    : load option information from file.
 --driver (-d) <driver>                  : firefox (default) | chrome | ie | edge | safari | htmlunit | remote | appium | FQCN-of-WebDriverFactory
 --headless                              : use headless mode if driver is supported (currently, Chrome and Firefox)
 --parallel <threads>                    : run multiple test files in parallel (if set <threads> to "max", all files are executed in parallel at once)
 --profile (-p) <name>                   : profile name (Firefox only *1)
 --profile-dir (-P) <dir>                : profile directory (Firefox only *1)
 --chrome-experimental-options <file>    : path to json file specify experimental options for chrome (Chrome only *1)
 --chrome-extension <file>               : chrome extension file (multiple, Chrome only *1)
 --proxy-type <proxy-type>               : proxy type (manual (default if set --proxy) | pac | autodetect | system)
 --proxy <proxy>                         : [manual] proxy host and port (HOST:PORT) (excepting IE) / [pac] PAC URL
 --proxy-user <user>                     : proxy username (HtmlUnit only *2)
 --proxy-password <password>             : proxy password (HtmlUnit only *2)
 --no-proxy <hosts>                      : no-proxy hosts
 --cli-args <arg>                        : add command line arguments at starting up driver (multiple)
 --remote-url <url>                      : Remote test runner URL (Remote only)
 --remote-platform <platform>            : Desired remote platform (Remote only)
 --remote-browser <browser>              : Desired remote browser (Remote only)
 --remote-version <browser-version>      : Desired remote browser version (Remote only)
 --highlight (-H)                        : highlight locator always.
 --interactive (-i)                      : interactive mode.
 --screenshot-dir (-s) <dir>             : override captureEntirePageScreenshot directory.
 --screenshot-all (-S) <dir>             : take screenshot at all commands to specified directory.
 --screenshot-on-fail <dir>              : take screenshot on fail commands to specified directory.
 --screenshot-scroll-timeout <timeout>   : set scroll timeout (ms) for taking screenshot. (default: 100)
 --ignore-screenshot-command             : ignore captureEntirePageScreenshot command.
 --baseurl (-b) <baseURL>                : override base URL set in selenese.
 --firefox <path>                        : path to 'firefox' binary. (implies '--driver firefox')
 --geckodriver <path>                    : path to 'geckodriver' binary. (implies '--driver firefox')
 --chromedriver <path>                   : path to 'chromedriver' binary. (implies '--driver chrome')
 --iedriver <path>                       : path to 'IEDriverServer' binary. (implies '--driver ie')
 --edgedriver <path>                     : path to Edge 'WebDriver' binary. (implies '--driver edge')
 --xml-result <dir>                      : output XML JUnit results to specified directory.
 --html-result <dir>                     : output HTML results to specified directory.
 --timeout (-t) <timeout>                : set timeout (ms) for waiting. (default: 30000 ms)
 --max-retries <maxRetries>              : set maximum number of retries for a given step. (default: 0)
 --set-speed <speed>                     : same as executing setSpeed(ms) command first.
 --height <height>                       : set initial height. (excluding mobile)
 --width <width>                         : set initial width. (excluding mobile)
 --alerts-policy VAL                     : The default behaviour for unexpected alerts (accept/dismiss/accept_and_notify/dismiss_and_notify/ignore)
 --define (-D) <key>[:<type>][+]=<value> : define parameters for capabilities. <type> is a value type: str (default), int or bool (multiple)
 --var (-V) <var-name>=<json-value>      : set JSON value to variable with a specified name. (multiple)
 --rollup <file>                         : define rollup rule by JavaScript. (multiple)
 --cookie-filter <+RE|-RE>               : filter cookies to log by RE matching the name. ("+" is passing, "-" is suppressing)
 --log-filter <+type|-type>              : filter the logging information by the specified type. (multiple. "+" is passing, "-" is suppressing. type: cookie, title, url, pageinfo(= cookie & title & url))
 --command-factory <FQCN>                : register user defined command factory. (See Note *3)
 --no-exit                               : don't call System.exit at end.
 --strict-exit-code                      : return strict exit code, reflected by selenese command results at end. (See Note *4)
 --max-time <max-time>                   : Maximum time in seconds that you allow the entire operation to take.
 --no-replace-alert-method               : disable replacement of alert methods
 --help (-h)                             : show this message.

[Note]
*1 It is available if using "--driver remote --remote-browser firefox".

*2 If you want to use basic and/or proxy authentication on Firefox, then create new profile, install AutoAuth plugin, configure all settings, access test site with the profile, and specify the profile by --profile option.

*3 Use "java -cp ...:selenese-runner.jar Main --command-factory ...".
   Because "java" command ignores all class path settings, when using "-jar" option.

*4 The list of exit code (strict/normal) is follows:
   - 0/0: SUCCESS
   - 2/0: WARNING
   - 3/3: FAILURE
   - 4/3: ERROR
   - 5/0: UNEXECUTED
   - 6/3: MAX_TIME_EXCEEDED
   - 70/70: FATAL
   - 64/64: USAGE

Requirements

  • Java 8 or later.
  • Apache Maven 2.x or later to build.

Building the Application

  • Install Apache Maven.
  • clone this repository
  • run build script mvn -P package

That will create the selenese-runner.jar file within the 'target' directory.

Options

Configuration file (1.8.0 or later)

You can read option information from the following configuration file by using "--config" option.

You can overwrite the information by additional command line options.

# configuration file format.

driver: DRIVER_NAME
profile: PROFILE_NAME
profile-dir: /PATH/TO/PROFILE/DIRECTORY
proxy: PROXY_HOST
proxy-user: PROXY_USER
proxy-password: PROXY_PASSWORD
no-proxy: NO_PROXY_HOSTS
cli-args: DRIVER_CLI_ARG1
  DRIVER_CLI_ARG2
  DRIVER_CLI_ARG3
remote-url: http://remote.example.com:4444/wd/hub
remote-platform: REMOTE_PLATFORM
remote-browser: REMOTE_BROWSER
remote-version: REMOTE_VERSION
# "highlight" parameter is "true" or "false".
highlight: true
screenshot-dir: /PATH/TO/SCREENSHOT/DIRECTORY
screenshot-all: /PATH/TO/SCREENSHOT/DIRECTORY/ALL
screenshot-on-fail: /PATH/TO/SCREENSHOT/DIRECTORY/ON/FAIL
# "ignore-screenshot-command" parameter is "true" or "false".
ignore-screenshot-command: true
baseurl: http://baseurl.example.com/
firefox: /PATH/TO/FIREFOX/BINARY
chromedriver: /PATH/TO/CHROMEDRIVER/BINARY
iedriver: /PATH/TO/IEDRIVER/BINARY
phantomjs: /PATH/TO/PHANTOMJS/BINARY
xml-result: /PATH/TO/XML/RESULT/DIRECTORY
html-result: /PATH/TO/HTML/RESULT/DIRECTORY
# The unit of "timeout" parameter is millisecounds.
timeout: 30000
# The unit of "set-speed" parameter is millisecounds.
set-speed: 100
# The unit of "height" parameter is pixcels.
height: 1024
# The unit of "width" parameter is pixcels.
width: 768
define: CAPABILITY_KEY1=CAPABILITY_VALUE1
   CAPABILITY_KEY2=CAPABILITY_VALUE2
   CAPABILITY_KEY3+=CAPABILITY_VALUE31
   CAPABILITY_KEY3+=CAPABILITY_VALUE32
   CAPABILITY_KEY3+=CAPABILITY_VALUE33
rollup: /PATH/TO/ROLLUP/FILE
cookie-filter: COOKIE_FILTER_REGEXP
command-factory: full.qualify.class.Name

Firefox, Chrome and PhantomJS driver

If you want to add command line options to above driver's binary, add following options:

java -jar selenese-runner.jar --driver DRIVER_NAME \
  --cli-args ARG1 \
  --cli-args ARG2 \
  ...

Example:

  • Firefox

      java -jar selenese-runner.jar --driver firefox \
        --cli-args -jsconsole \
        ...
    
  • Chrome

      java -jar selenese-runner.jar --driver chrome \
        --cli-args --incognito \
        --cli-args --ignore-certificate-errors \
        ...
    
  • PhantomJS

      java -jar selenese-runner.jar --driver phantomjs \
        --cli-args --ssl-certificates-path=/PATH/TO/CERTS-DIR/ \
        ...
    

Rollup

"--rollup" option and "rollup" command are used for a definition and execution of a user-defined command.

Refer to the following for how to write "rollup" script:

However, this feature has the following limitations:

  • supported properties of rollup rule: ** name ** args ** expandedCommands or getExpandedCommans
  • cannot access any browser object.

Cookie filter

You can filter cookies to log by the regular expression matching the name.

Example:

  • logging the cookie whose name ends with "ID":

      java -jar selenese-runner.jar --cookie-filter +'ID$' ...
    
  • don't logging the cookie whose name contains "__utm":

      java -jar selenese-runner.jar --cookie-filter -__utm ...
    

User defined command factory

You can register user defined command factory:

java -cp YOUR_CLASS_PATH:selenese-runner.jar Main \
  --command-factory your.command.factory.ClassName ...

Note:

  • Use the above command line instead of "java -jar ...". Because "java" command ignores all class path settings, when using "-jar" option.

  • Top-level Main class is contained ONLY in stand-alone "selenese-runner.jar", and is not contained in "selenese-runner-java-X.Y.Z.jar" in maven repository. Please use "jp.vmi.selenium.selenese.Main" instead of "Main" if you want to use this feature with the jar in maven repository.

Original Commands

include

Usage: include FILENAME

This command include and execute FILENAME test-case.

You can use variables in FILENAME.

See the test-case example.

License

The Apache License, Version 2.0.

see "LICENSE" file.

selenese-runner-java's People

Contributors

andreacoloru avatar aymandf avatar blutorange avatar cesarsotovalero avatar chenzhang22 avatar chenzhangg avatar deki avatar dependabot[bot] avatar derekjleggett avatar harinus avatar hayato1980 avatar janblok avatar jbrazile avatar koichirok avatar lukian-tabandzhov avatar mcclellanmj avatar nbertram avatar patchpump avatar rlasinski avatar shenlian8 avatar stevenebutler avatar uchida avatar vmi avatar yec avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

selenese-runner-java's Issues

Element not scrolled into viewport

Hi, I'm getting an error when trying to click an element that apparently is not in view. Namely, the error is the following:

[ERROR] - [Failure: The point at which the driver is attempting to click on the element was not scrolled into the viewport. (WARNING: The server did not provide any stacktrace information) / Command duration or timeout: 188 milliseconds / Build info: version: 'unknown', revision: 'unknown', time: 'unknown' / System info: os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_07' / Session ID: 7b850c15-1c46-4bb9-b704-c347ee2cb50c / Driver info: org.openqa.selenium.ie.InternetExplorerDriver / Capabilities [{platform=WINDOWS, javascriptEnabled=true, cssSelectorsEnabled=true, handlesAlerts=true, browserName=internet explorer, nativeEvents=true, takesScreenshot=true, version=9}]]

I'm even preceding the click command with a waitForVisible, but the latter succeeds while the former still fails...

I know this is an issue in WebDriver (http://code.google.com/p/selenium/issues/detail?id=4390) but is there any workaround I can use until the problem is fixed?

Cheers

log comment option.

selenese script syntax allow to comment html style comment .

Add the option to log these comment.

allow execution speed adjustment

In my tests I use the selenese command 'setSpeed' to run my tests more slowly than the default speed. Selenese runner seems to ignore this command.

remove dependency to logback

  • BACKGROUND
    I am implementing jenkins plugin to use selenese-runner-java.
    The plugin depending jenkins and selenese-runner-java, occured following error when do "mvn package".
    Because selenese-runner-java depend on logback-classic.

T E S T S

Running InjectedTest
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/Users/hayato/.m2/repository/ch/qos/logback/logback-classic/1.0.6/logback-classic-1.0.6.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/Users/hayato/.m2/repository/org/slf4j/slf4j-nop/1.5.3/slf4j-nop-1.5.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.selector.DefaultContextSelector]

  • SUGGESTION

    Do away with using SLF4j and Logback tologging test result and process, use original Logging process.

Problems with `close`

Apparently close can fail, at least when using new windows. Here's a test case:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="https://www.google.com" />
<title>MinimalTest</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">MinimalTest</td></tr>
</thead><tbody>
<tr>
    <td>setSpeed</td>
    <td>1000</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>/</td>
    <td></td>
</tr>
<tr>
    <td>openWindow</td>
    <td>/images</td>
    <td></td>
</tr>
<tr>
    <td>close</td>
    <td></td>
    <td></td>
</tr>
</tbody></table>
</body>
</html>

Relevant output:

[2012-12-12 14:27:06.556] [INFO] Command#4: close()
[2012-12-12 14:27:06.585] [ERROR] Window not found. The browser window may have been closed.

Works fine on IDE. Tested with latest snapshot.

Improve error logging for boolean assertions

Currently all assertions log success/failure in terms of the result and expected value. This means a failed boolean assertion will log the following:

[Warning: Assertion failed (Result: [true] / Expected: [false])]

In general this shouldn't be a problem since before such a message you would see the command that caused it being logged. However, the command logging goes to standard out and the failed assertion logging goes to standard error. This mean if you are just monitoring standard error you will get a message that is not so informative.

My use case is that I'm running selenese-runner from a Jenkins job and publishing the JUnit reports as usual. This means that standard error and standard out are separated, which makes them difficult to relate to each other.

alert/verifyConfirmation don't work

[2012-09-03 23:13:21.000] [INFO] Command#18: verifyConfirmation("***")
[2012-09-03 23:13:21.000] [ERROR] getConfirmation()
[2012-09-03 23:13:21.015] [ERROR] There were no confirmations
(snip)
[2012-09-03 23:13:21.015] [ERROR] There were no confirmations
[2012-09-03 23:13:21.046] [INFO] End(48.7sec): TestSuite[default-00]
com.thoughtworks.selenium.SeleniumException: There were no confirmations
at org.openqa.selenium.internal.seleniumemulation.AlertOverride.getNextConfirmation(AlertOverride.java:69)
at org.openqa.selenium.internal.seleniumemulation.GetConfirmation.handleSeleneseCommand(GetConfirmation.java:30)
at org.openqa.selenium.internal.seleniumemulation.SeleneseCommand.apply(SeleneseCommand.java:29)
at org.openqa.selenium.internal.seleniumemulation.Timer.run(Timer.java:38)
at org.openqa.selenium.WebDriverCommandProcessor.execute(WebDriverCommandProcessor.java:144)
at org.openqa.selenium.WebDriverCommandProcessor.doCommand(WebDriverCommandProcessor.java:74)
at jp.vmi.selenium.selenese.TestCase.doBuiltInCommand(TestCase.java:110)
at jp.vmi.selenium.selenese.command.Assertion.doCommand(Assertion.java:82)
at jp.vmi.selenium.selenese.TestCase.doCommand(TestCase.java:242)
at jp.vmi.selenium.selenese.inject.CommandLogInterceptor.invoke(CommandLogInterceptor.java:100)
at jp.vmi.selenium.selenese.TestCase.execute(TestCase.java:251)
at jp.vmi.selenium.selenese.inject.ExecuteTestCaseInterceptor.invoke(ExecuteTestCaseInterceptor.java:44)
at jp.vmi.selenium.selenese.TestSuite.execute(TestSuite.java:86)
at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:32)
at jp.vmi.selenium.selenese.Runner.run(Runner.java:161)
at jp.vmi.selenium.selenese.Main.run(Main.java:237)
at jp.vmi.selenium.selenese.Main.main(Main.java:257)
[2012-09-03 23:13:21.312] [WARN] null

JavaScript error in type command on IE9 & WindowsServer2008

environment:Windows 2008Server R2
browser: IE9

SeleneseRunner output following error when it run type command.


[2012-10-08 17:09:54.663] [ERROR] - [failed command:Command#2: type("id=username", "hayato") result:JavaScript error (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 172 milliseconds
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Windows Server 2008 R2', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_07'
Driver info: driver.version: RemoteWebDriver

Problems with `openWindow`

The openWindow command seems not to work. Here's a an example test case:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="https://www.google.com" />
<title>MinimalTest</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">MinimalTest</td></tr>
</thead><tbody>
<tr>
    <td>setSpeed</td>
    <td>1000</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>/</td>
    <td></td>
</tr>
<tr>
    <td>openWindow</td>
    <td>/images</td>
    <td></td>
</tr>
</tbody></table>
</body>
</html>

The new window takes a while to load and then when it does Firefox complains about an unresponsive script. I get the following output:

[2012-12-05 15:09:05.190] [INFO] Start: Selenese Runner 1.1.1-SNAPSHOT
[2012-12-05 15:09:07.473] [INFO] Initialized: FirefoxDriver
[2012-12-05 15:09:07.712] [INFO] Start: TestSuite[default-00]
[2012-12-05 15:09:07.868] [INFO] Start: TestCase[MinimalTest] (MinimalTest.html)
[2012-12-05 15:09:07.868] [INFO] baseURL: http://www.google.com
[2012-12-05 15:09:07.872] [INFO] Command#1: setSpeed("1000")
[2012-12-05 15:09:07.898] [INFO] - [Success] URL: [about:blank] / Title: []
[2012-12-05 15:09:08.898] [INFO] Command#2: open("/")
[2012-12-05 15:09:09.560] [INFO] - [Success] URL: [http://www.google.nl/] / Title: [Google]
[2012-12-05 15:09:09.560] [INFO] - Cookie: NID=[66=ihzo77fBKpEtv8VR-m7saHHZDQ71swVcG4kZO5FKOlzBGvt7EL8jKozoFQleJtccVqzlyIsoKK1sGDq5lEiB5PD2zFmWtmbf-9OewBD5d1m0EHfEl8tJoOdEl5hiUvi7] (domain=.google.nl, path=/, expire=2013-06-06 16:09:09)
[2012-12-05 15:09:09.560] [INFO] - Cookie: PREF=[ID=e2d0f64fdcb20e6e:FF=0:TM=1354716549:LM=1354716549:S=aL5gztJqncJrUAEO] (domain=.google.nl, path=/, expire=2014-12-05 15:09:09)
[2012-12-05 15:09:10.561] [INFO] Command#3: openWindow("/images", "")
[2012-12-05 15:09:31.886] [ERROR] receiver "TestCase[MinimalTest] (MinimalTest.html)" is not TestCase: java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
[2012-12-05 15:09:31.886] [ERROR] java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
[2012-12-05 15:09:31.889] [INFO] End(24.0sec): TestCase[MinimalTest] (MinimalTest.html)
[2012-12-05 15:09:31.889] [ERROR] java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
[2012-12-05 15:09:31.889] [ERROR] java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
[2012-12-05 15:09:31.889] [INFO] End(24.2sec): TestSuite[default-00]
java.lang.RuntimeException: java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
    at jp.vmi.selenium.selenese.inject.CommandLogInterceptor.invoke(CommandLogInterceptor.java:108)
    at jp.vmi.selenium.selenese.TestCase.execute(TestCase.java:196)
    at jp.vmi.selenium.selenese.inject.ExecuteTestCaseInterceptor.invoke(ExecuteTestCaseInterceptor.java:48)
    at jp.vmi.selenium.selenese.TestSuite.execute(TestSuite.java:91)
    at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:39)
    at jp.vmi.selenium.selenese.Runner.run(Runner.java:218)
    at jp.vmi.selenium.selenese.Main.run(Main.java:261)
    at jp.vmi.selenium.selenese.Main.main(Main.java:281)
Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.util.List
    at jp.vmi.selenium.selenese.cmdproc.Eval.eval(Eval.java:59)
    at jp.vmi.selenium.selenese.cmdproc.OpenWindow.handleSeleneseCommand(OpenWindow.java:25)
    at jp.vmi.selenium.selenese.cmdproc.OpenWindow.handleSeleneseCommand(OpenWindow.java:9)
    at org.openqa.selenium.internal.seleniumemulation.SeleneseCommand.apply(SeleneseCommand.java:35)
    at jp.vmi.selenium.selenese.cmdproc.CustomCommandProcessor.execute(CustomCommandProcessor.java:76)
    at jp.vmi.selenium.selenese.command.BuiltInCommand.doCommand(BuiltInCommand.java:50)
    at jp.vmi.selenium.selenese.TestCase.doCommand(TestCase.java:187)
    at jp.vmi.selenium.selenese.inject.CommandLogInterceptor.invoke(CommandLogInterceptor.java:100)
    ... 7 more
[2012-12-05 15:09:31.910] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:31.910] [INFO] Retrying request
[2012-12-05 15:09:31.913] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:31.913] [INFO] Retrying request
[2012-12-05 15:09:31.917] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:31.918] [INFO] Retrying request
[2012-12-05 15:09:33.962] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:33.962] [INFO] Retrying request
[2012-12-05 15:09:34.002] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:34.002] [INFO] Retrying request
[2012-12-05 15:09:34.043] [INFO] I/O exception (org.apache.http.NoHttpResponseException) caught when processing request: The target server failed to respond
[2012-12-05 15:09:34.043] [INFO] Retrying request
[2012-12-05 15:09:34.137] [WARN] Error communicating with the remote browser. It may have died.
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Linux', os.arch: 'i386', os.version: '2.6.32-131.6.1.el6.i686', java.version: '1.6.0_20'
Driver info: driver.version: RemoteWebDriver
[2012-12-05 15:09:34.137] [INFO] Quit: FirefoxDriver

Tested with latest snapshot on Firefox 17.0.1.

Not good log on specifing no file in command line use.

java -jar ./selenese-runner.jar no_such_file.html
[2012-09-07 15:07:12.244] [INFO] Start: Selenese Runner 1.0.1-SNAPSHOT
[2012-09-07 15:07:29.199] [INFO] Initialized: FirefoxDriver
[2012-09-07 15:07:29.763] [INFO] Start: TestSuite[default-00]
[2012-09-07 15:07:29.831] [INFO] Start: jp.vmi.selenium.selenese.ErrorTestCase$$EnhancerByGuice$$6b5e6987@4d898115
[2012-09-07 15:07:29.844] [INFO] End(0.0sec): jp.vmi.selenium.selenese.ErrorTestCase$$EnhancerByGuice$$6b5e6987@4d898115
[2012-09-07 15:07:29.872] [INFO] End(0.1sec): TestSuite[default-00]
[2012-09-07 15:07:29.940] [INFO] Quit: FirefoxDriver

exit 3

change options

--screenshot-dir => --screenshot=DIR ... affect entireTakeScreenshot only. (does override by current directory if not specified?)
--screenshot-all => --screenshot-all[=DIR] ... DIR is optional. (use hasOptionalArg()) default is current directory.
--result-dir DIR => --result[=DIR] ... DIR is optional. default is current directory.

storedVars doesn't work

I have a test with storeEval,
command: storeEval("((storedVars['logoutpresent']==true)?storedVars['link_logout']:storedVars['body'])"
and the output is that: ReferenceError: storedVars is not defined

Commands "verifyNotText", "waitForNotText", "verifyElementNotPresent" and "verifyNotVisible" not working

Here is a minimal example for "verifyNotText":

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="https://www.google.com" />
<title>MinimalTest</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">MinimalTest</td></tr>
</thead><tbody>
<tr>
    <td>setSpeed</td>
    <td>1000</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>/</td>
    <td></td>
</tr>
<tr>
    <td>verifyNotText</td>
    <td>id=addlang</td>
    <td></td>
</tr>
</tbody></table>
</body>
</html>

Ran with:

java -jar selenese-runner.jar -d firefox -b http://www.google.com MinimalTest.html

Output:

[2012-11-21 14:34:05.611] [INFO] Start: Selenese Runner 1.0.2-SNAPSHOT
[2012-11-21 14:34:08.478] [INFO] Initialized: FirefoxDriver
[2012-11-21 14:34:08.713] [INFO] Start: TestSuite[default-00]
[2012-11-21 14:34:08.860] [ERROR] No such command: verifyNotText
[2012-11-21 14:34:08.861] [INFO] End(0.1sec): TestSuite[default-00]
com.thoughtworks.selenium.SeleniumException: No such command: verifyNotText
    at jp.vmi.selenium.selenese.command.CommandFactory.newCommand(CommandFactory.java:139)
    at jp.vmi.selenium.selenese.command.CommandFactory.newCommand(CommandFactory.java:88)
    at jp.vmi.selenium.selenese.TestCaseParser.parse(TestCaseParser.java:70)
    at jp.vmi.selenium.selenese.Parser.parse(Parser.java:101)
    at jp.vmi.selenium.selenese.TestSuite.execute(TestSuite.java:88)
    at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:39)
    at jp.vmi.selenium.selenese.Runner.run(Runner.java:218)
    at jp.vmi.selenium.selenese.Main.run(Main.java:261)
    at jp.vmi.selenium.selenese.Main.main(Main.java:281)
[2012-11-21 14:34:08.920] [INFO] Quit: FirefoxDriver

Similar example can be created for the other commands.

jp.vmi.selenium.selenese.ProxyTest.startAndKill failed by time over

java.lang.Exception: test timed out after 10000 milliseconds
at java.lang.StringBuilder.append(StringBuilder.java:132)
at java.net.URLStreamHandler.parseURL(URLStreamHandler.java:249)
at sun.net.www.protocol.file.Handler.parseURL(Handler.java:67)
at java.net.URL.(URL.java:612)
at java.net.URL.(URL.java:480)
at sun.misc.URLClassPath$FileLoader.getResource(URLClassPath.java:1034)
at sun.misc.URLClassPath.getResource(URLClassPath.java:195)
at java.net.URLClassLoader$1.run(URLClassLoader.java:358)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at com.kenai.constantine.ConstantSet.iterator(ConstantSet.java:221)
at org.jruby.Ruby.loadConstantSet(Ruby.java:3860)
at org.jruby.libraries.FcntlLibrary.load(FcntlLibrary.java:49)
at org.jruby.runtime.load.LoadService.reflectedLoad(LoadService.java:407)
at org.jruby.ext.LateLoadingLibrary.load(LateLoadingLibrary.java:48)
at org.jruby.runtime.load.LoadService.tryLoadingLibraryOrScript(LoadService.java:745)
at org.jruby.runtime.load.LoadService.smartLoad(LoadService.java:332)
at org.jruby.runtime.load.LoadService.require(LoadService.java:379)
at org.jruby.runtime.load.LoadService.lockAndRequire(LoadService.java:304)
at org.jruby.RubyKernel.requireCommon(RubyKernel.java:1050)
at org.jruby.RubyKernel.require(RubyKernel.java:1033)
at org.jruby.RubyKernel$s$1$0$require.call(RubyKernel$s$1$0$require.gen:65535)
at org.jruby.internal.runtime.methods.JavaMethod$JavaMethodOneOrNBlock.call(JavaMethod.java:319)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
at org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
at org.jruby.ast.RootNode.interpret(RootNode.java:129)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_ROOT(ASTInterpreter.java:119)
at org.jruby.Ruby.runInterpreter(Ruby.java:724)
at org.jruby.Ruby.loadFile(Ruby.java:2487)
at org.jruby.runtime.load.ExternalScript.load(ExternalScript.java:66)
at org.jruby.runtime.load.LoadService.tryLoadingLibraryOrScript(LoadService.java:745)
at org.jruby.runtime.load.LoadService.smartLoad(LoadService.java:332)
at org.jruby.runtime.load.LoadService.require(LoadService.java:379)
at org.jruby.runtime.load.LoadService.lockAndRequire(LoadService.java:304)
at org.jruby.RubyKernel.requireCommon(RubyKernel.java:1050)
at org.jruby.RubyKernel.require(RubyKernel.java:1033)
at org.jruby.RubyKernel$s$1$0$require.call(RubyKernel$s$1$0$require.gen:65535)
at org.jruby.internal.runtime.methods.JavaMethod$JavaMethodOneOrNBlock.call(JavaMethod.java:319)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
at org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
at org.jruby.ast.RootNode.interpret(RootNode.java:129)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_ROOT(ASTInterpreter.java:119)
at org.jruby.Ruby.runInterpreter(Ruby.java:724)
at org.jruby.Ruby.loadFile(Ruby.java:2487)
at org.jruby.runtime.load.ExternalScript.load(ExternalScript.java:66)
at org.jruby.runtime.load.LoadService.tryLoadingLibraryOrScript(LoadService.java:745)
at org.jruby.runtime.load.LoadService.smartLoad(LoadService.java:332)
at org.jruby.runtime.load.LoadService.require(LoadService.java:379)
at org.jruby.runtime.load.LoadService.lockAndRequire(LoadService.java:304)
at org.jruby.RubyKernel.requireCommon(RubyKernel.java:1050)
at org.jruby.RubyKernel.require(RubyKernel.java:1033)
at org.jruby.RubyKernel$s$1$0$require.call(RubyKernel$s$1$0$require.gen:65535)
at org.jruby.internal.runtime.methods.JavaMethod$JavaMethodOneOrNBlock.call(JavaMethod.java:319)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
at org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
at org.jruby.ast.RootNode.interpret(RootNode.java:129)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_ROOT(ASTInterpreter.java:119)
at org.jruby.Ruby.runInterpreter(Ruby.java:724)
at org.jruby.Ruby.loadFile(Ruby.java:2487)
at org.jruby.runtime.load.ExternalScript.load(ExternalScript.java:66)
at org.jruby.runtime.load.LoadService.tryLoadingLibraryOrScript(LoadService.java:745)
at org.jruby.runtime.load.LoadService.smartLoad(LoadService.java:332)
at org.jruby.runtime.load.LoadService.require(LoadService.java:379)
at org.jruby.runtime.load.LoadService.lockAndRequire(LoadService.java:304)
at org.jruby.RubyKernel.requireCommon(RubyKernel.java:1050)
at org.jruby.RubyKernel.require(RubyKernel.java:1033)
at org.jruby.RubyKernel$s$1$0$require.call(RubyKernel$s$1$0$require.gen:65535)
at org.jruby.internal.runtime.methods.JavaMethod$JavaMethodOneOrNBlock.call(JavaMethod.java:319)
at org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:312)
at org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:169)
at org.jruby.ast.FCallOneArgNode.interpret(FCallOneArgNode.java:36)
at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
at org.jruby.ast.RootNode.interpret(RootNode.java:129)
at org.jruby.evaluator.ASTInterpreter.INTERPRET_ROOT(ASTInterpreter.java:119)
at org.jruby.Ruby.runInterpreter(Ruby.java:724)
at org.jruby.Ruby.runInterpreter(Ruby.java:732)
at org.jruby.embed.internal.EmbedEvalUnitImpl.run(EmbedEvalUnitImpl.java:120)
at org.jruby.embed.ScriptingContainer.runUnit(ScriptingContainer.java:1263)
at org.jruby.embed.ScriptingContainer.runScriptlet(ScriptingContainer.java:1256)
at jp.vmi.selenium.selenese.Proxy.createScriptingContainer(Proxy.java:25)
at jp.vmi.selenium.selenese.WebrickServer.(WebrickServer.java:31)
at jp.vmi.selenium.selenese.Proxy.(Proxy.java:15)
at jp.vmi.selenium.selenese.ProxyTest.startAndKill(ProxyTest.java:30)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.internal.runners.statements.FailOnTimeout$StatementThread.run(FailOnTimeout.java:62)

Behavior of `verifyValue` different than IDE for radio buttons

The following example succeeds in the Selenium IDE:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="https://www.google.com" />
<title>MinimalTest</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">MinimalTest</td></tr>
</thead><tbody>
<tr>
    <td>setSpeed</td>
    <td>1000</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>http://www.w3schools.com/html/html_forms.asp</td>
    <td></td>
</tr>
<tr>
    <td>verifyValue</td>
    <td>name=sex male</td>
    <td>off</td>
</tr>
<tr>
    <td>verifyValue</td>
    <td>name=sex female</td>
    <td>off</td>
</tr>
</tbody></table>
</body>
</html>

but fails with the selenese-runner with the following message:

[2012-12-03 16:25:39.396] [INFO] Command#3: verifyValue("name=sex male", "off")
[2012-12-03 16:25:39.576] [ERROR] - [Assertion failed (Result: [male] / Expected: [off])]
[2012-12-03 16:25:40.577] [INFO] Command#4: verifyValue("name=sex female", "off")
[2012-12-03 16:25:40.708] [ERROR] - [Assertion failed (Result: [female] / Expected: [off])]

Problems with variable expansion on `open`

Running the following example:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="https://www.google.com" />
<title>MinimalTest</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
<tr><td rowspan="1" colspan="3">MinimalTest</td></tr>
</thead><tbody>
<tr>
    <td>setSpeed</td>
    <td>1000</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>/</td>
    <td></td>
</tr>
<tr>
    <td>storeLocation</td>
    <td>url</td>
    <td></td>
</tr>
<tr>
    <td>open</td>
    <td>${url}/images</td>
    <td></td>
</tr>
</tbody></table>
</body>
</html>

I would expect http://www.google.com/images to be opened, but instead I get http://www.google.com/${url}/images. I checked with echo and the value of ${url} is correct, it just doesn't get expanded.

Tested with the latest snapshot.

screenshot capture not working

I'm getting a weird error when trying to use the screenshot capabilities. When running with option '-S screenshots' I'm getting the following error:

[ERROR] failed to rename captured screenshot image: screenshots/TestCase1_20121114_155019584_1.png

The directory does exist and the permissions should be correct (the same user that's running the selenese runner created the directory). I tried it with the latest version from the repository, as well as release 1.0.1. I'm runnig this on Scientific Linux 6.1 (kernel version 2.6.32-131.6.1.el6.i686)

Add option for "Highlight elements" functionality

I would be nice to have an option to turn on highlighting elements on every command. In Selenium RC there used to be a checkbox for this. There is also a plugin for Selenium IDE that provides this functionality.

This is useful for manually running Selenese scripts and seeing on the screen what is happening. My scenario is that I have my tests running as part of a continuous build and I would like to record what's going on by taking a screenshot on every command. Having the elements highlighted gives extremely valuable context information.

Improve fail on click message

when fail executing command, printed following stacktrace.
Meaning of "Failure" is not clear.

junit.framework.AssertionFailedError: Failure
at jp.vmi.selenium.selenese.junit.JUnitResult$Formatter.addFailure(JUnitResult.java:80)
at jp.vmi.selenium.selenese.junit.JUnitResult.addFailure(JUnitResult.java:166)
at jp.vmi.selenium.selenese.inject.ExecuteTestCaseInterceptor.invoke(ExecuteTestCaseInterceptor.java:32)
at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
at com.google.inject.internal.InterceptorStackCallback.intercept(InterceptorStackCallback.java:52)
at jp.vmi.selenium.selenese.TestCase$$EnhancerByGuice$$9b45f6ce.execute()
at jp.vmi.selenium.selenese.Runner.run(Runner.java:94)
at jp.vmi.selenium.selenese.TestSuite.execute(TestSuite.java:51)
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c.CGLIB$execute$3()
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c$$FastClassByGuice$$35a603a2.invoke()
at com.google.inject.internal.cglib.proxy.$MethodProxy.invokeSuper(MethodProxy.java:228)
at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:29)
at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
at com.google.inject.internal.InterceptorStackCallback.intercept(InterceptorStackCallback.java:52)
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c.execute()
at jp.vmi.selenium.selenese.Runner.run(Runner.java:94)
at jp.vmi.selenium.selenese.TestSuite.execute(TestSuite.java:51)
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c.CGLIB$execute$3()
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c$$FastClassByGuice$$35a603a2.invoke()
at com.google.inject.internal.cglib.proxy.$MethodProxy.invokeSuper(MethodProxy.java:228)
at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:29)
at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:72)
at com.google.inject.internal.InterceptorStackCallback.intercept(InterceptorStackCallback.java:52)
at jp.vmi.selenium.selenese.TestSuite$$EnhancerByGuice$$40574c8c.execute()
at jp.vmi.selenium.selenese.Runner.run(Runner.java:108)
at jp.vmi.selenium.selenese.Main.run(Main.java:199)
at jp.vmi.selenium.selenese.Main.main(Main.java:219)

Too many warnings by proxy

Too many follwing warnings at proxy test:

file:/C:/home/iwa/.m2/repository/org/jruby/jruby-stdlib/1.6.7.2/jruby-stdlib-1.6.7.2.jar!/META-INF/jruby.home/lib/ruby/1.8/webrick/server.rb:91 warning: try number 1 to get a selector

Testcase do not use google

when test and develop offline, mvn test fail because it is not able to access to google.com.

Use local webserver and use it on the test.

Add support for string-match patterns

It would be nice if string-match patterns were supported.

Here is an example of an error I get when using "regexp:sales.*" in a "verifyText" command:

[ERROR] - [Assertion failed (Result: [sales+2  Close] / Expected: [regexp:sales.*]]

Clearly if the regular expression was taken into account this should have succeeded.

add --overridebaseurl option

Add option to override baseurl set in selenese html.

usecase: baseurl in selenese is to production environment URL, but we need to run selenese test on staging environment.

Throw JAXBException via selenese-runner-java-*.jar

I develop Jenkins plugin emmbed selenese-runner-java.

The plugin throw following exception.

java.lang.ExceptionInInitializerError
at jp.vmi.selenium.selenese.inject.ExecuteTestSuiteInterceptor.invoke(ExecuteTestSuiteInterceptor.java:30)
at jp.vmi.selenium.selenese.Runner.run(Runner.java:161)
at jp.haya10.SeleneseRunnerBuilder.perform(SeleneseRunnerBuilder.java:65)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:682)
at hudson.model.Build$RunnerImpl.build(Build.java:177)
at hudson.model.Build$RunnerImpl.doRun(Build.java:139)
at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:448)
at hudson.model.Run.run(Run.java:1376)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:175)
Caused by: java.lang.RuntimeException: javax.xml.bind.JAXBException: "jp.vmi.junit.result" doesnt contain ObjectFactory.class or jaxb.index
at jp.vmi.junit.result.JUnitResult.(JUnitResult.java:35)
... 12 more
Caused by: javax.xml.bind.JAXBException: "jp.vmi.junit.result" doesnt contain ObjectFactory.class or jaxb.index
at com.sun.xml.internal.bind.v2.ContextFactory.createContext(ContextFactory.java:186)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:128)
at javax.xml.bind.ContextFinder.find(ContextFinder.java:290)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:372)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:337)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:244)
at jp.vmi.junit.result.JUnitResult.(JUnitResult.java:33)
... 12 more

Improve reports

Currently the reports generated are rather basic JUnit reports with only final failure/success information and standard out/error output. I was wondering if it would be possible to improve on this to generate something in the line of the old HTML reports of Selenium RC.

Namely, would it be possible to generate a HTML report with a table having:
| <result/output message> |

jp.vmi.selenium.selenese.ProxyTest.continuouslyInvoke failed by java.nio.BufferOverflowException

java.nio.BufferOverflowException
at java.nio.HeapByteBuffer.put(HeapByteBuffer.java:200)
at org.jruby.util.io.ChannelStream.bufferedWrite(ChannelStream.java:1087)
at org.jruby.util.io.ChannelStream.access$700(ChannelStream.java:62)
at org.jruby.util.io.ChannelStream$OutputStreamAdapter.write(ChannelStream.java:1614)
at org.jruby.util.IOOutputStream.write(IOOutputStream.java:102)
at java.io.PrintStream.write(PrintStream.java:480)
at sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:221)
at sun.nio.cs.StreamEncoder.implFlushBuffer(StreamEncoder.java:291)
at sun.nio.cs.StreamEncoder.flushBuffer(StreamEncoder.java:104)
at java.io.OutputStreamWriter.flushBuffer(OutputStreamWriter.java:185)
at java.io.PrintStream.write(PrintStream.java:527)
at java.io.PrintStream.print(PrintStream.java:669)
at org.jruby.Ruby.printError(Ruby.java:2468)
at org.jruby.embed.internal.EmbedEvalUnitImpl.run(EmbedEvalUnitImpl.java:131)
at org.jruby.embed.ScriptingContainer.runUnit(ScriptingContainer.java:1263)
at org.jruby.embed.ScriptingContainer.runScriptlet(ScriptingContainer.java:1256)
at jp.vmi.selenium.selenese.Proxy.createScriptingContainer(Proxy.java:27)
at jp.vmi.selenium.selenese.WebrickServer.(WebrickServer.java:31)
at jp.vmi.selenium.selenese.Proxy.(Proxy.java:15)
at jp.vmi.selenium.selenese.ProxyTest.continuouslyInvoke(ProxyTest.java:19)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
at org.apache.maven.surefire.junitcore.ClassDemarcatingRunner.run(ClassDemarcatingRunner.java:58)
at org.junit.runners.Suite.runChild(Suite.java:128)
at org.junit.runners.Suite.runChild(Suite.java:24)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.