Test Runner

RCPTT Test Runner is command-line tool for launching RCPTT tests.
It takes various options like path to RCPTT projects, application-under-test and other parameters, runs all tests and produces reports in HTML and JUnit XML formats.

Quick start

Download and modify sample scripts below (parameters that need to be set/changed are explained in scipt commends):

Path prefix for application-under-test's workspace. The workspace prefix given will be suffixed with incrementing restart index to make sure no data is lost in case of application-under-test restart, hang or crash. See also reuseExistingWorkspace.

"C:\work\aut-workspace-"

Yes

junitReport

File path to save JUnit report with test exec results

"C:\work\results.xml"

No

htmlReport

File path to save HTML report with test exec results

"C:\work\results.html"

No

autConsolePrefix

File prefix for application-under-test process output. It will be appended with incrementing restart index for the same reason as -autWsPrefix arg.

Generate report with custom reporting renderer. "id;path" format should be used to specify report renderer id and path to export.

"custom.report.id;C:\results\custom.report"

No

noSecurityOverride

If provided, -eclipse.keyring parameter will not be specified. Also -testOptions could contain "overrideSecurityStorage=false" for same effect.

This argument does not have value

No

memoryUsage

If specified, print AUT memory usage in Runner stdout

This argument does not have value

No

tests

Semicolon-separated list of test name glob patterns (* - any chars, ? - exactly one char). If this argument is set, RCPTT runner executes listed test cases only. This argument also works with combination with suites argument, i.e. at first Runner collects all tests from provided suites and then filters it by test names

-tests myTest.test or -test myTest*

No

reuseExistingWorkspace

If present, autWsPrefix is treated as full path to the existing workspace. This workspace is never recreated and always reused.

This argument does not have value

No

Injection options

Injection mechanism allows to install some extra features into application-under-test before test execution. This might be useful in two cases:

The product being tested is distributed as an update site, so there's no default all-in-one RCP application. In this case Eclipse SDK (or other eclipse package) can be used as application-under-test and plugins being tested will be installed into it.

Application-under-test requires some extra plugins for testing, and these plugins are undesirable in a final product

Injection mechanism currently does not resolve dependencies automatically, i.e. it just puts specified plugins/features into an application, but does not make sure that all prerequisites are installed.

Injecting from Update Site

In command line it is specified as argument with name injection.site where value is update site URL optionally followed by list of features separated by semicolon. If list of features is omitted, then all features from given site will be installed

It is possible to specify this argument several times to inject features from more than one update site.

Injecting from a directory

This way is similar to dropping some plugins into eclipse/plugins folder:

-injection:dir

It is possible to specify this argument several times to inject plugins from more than one directory

RCPTT Runtime options

This table summarizes RCPTT runtime options which are rarely need to be modified and can be specified in testOptions argument. In RCPTT IDE these options can be set by going to Preferences -> RCP Testing Tool -> Advanced Options.

Option Name

Default value

Description

passedTestDetails

false

When true, include output of 'take-screenshot' and 'trace' ECL commands into a report

testExecTimeout

300

Timeout for a single test execution in seconds

contextRunnableTimeout

180000

Context applying timeout in milliseconds

contextsWaitforjobsTimeout

30000

If there are any jobs started after context applying, wait for their completion during this time (in milliseconds).

jobDebugjobTimeout

300000

Timeout in milliseconds for jobs scheduled from eclipse Debug plugin.

jobNulifyRescheduleMaxValue

50

If job reschedules itself more than times specified by this parameter, RCPTT stops setting delay to 0 (see jobScheduleDelayedMaxtime parameter).

jobSleepingStepTime

200

When job is in sleeping mode (see jobTreatAsSleeingTimeout option), execute commands with given delay (in milliseconds) between commands.

If job executes more than this time (in milliseconds) and sleeps (i.e. executing Thread.sleep() or Object.wait()), then RCPTT considers that this job is waiting for some user actions and continues to the next command.

timerExecsWaitNullify

100

If Display.timerExec is scheduled for the delay less than this value (in milliseconds), set delay to 0.

autStartupTimeout

300

How many seconds Runner should wait for application startup.

jobHangTimeout

30000

Job hang skip timeout in milliseconds. If job is running longer than this time, RCPTT Runtime considers that it is hung and moves to the next command.

jobSchelduleDelayedMaxtime

600

Max job scheduled delay to be waited for in milliseconds. If job is scheduled with delay less than this value, RCPTT sets delay to 0 and waits for job completion (also see jobNullifyRescheduleMaxValue). Otherwise RCPTT Runtime does not wait for job completion if it is scheduled with a delay greater than this value.

launchingKillAutOnConnectError

false

Kill AUT on connect error. Whether Runner should kill application-under-test if it cannot connect to it.

eclExecutionDelay

0

Wait for a given milliseconds between each ECL command. This can be useful when things go wrong at some point and it is hard to determine when by looking at execution. Setting this value to, say, 500, allows to inspect RCPTT actions in more details.