test_ospl.Process

Module test_ospl :: Class Process |
[hide private]
[frames] | no frames]

# Class Process

source code

Represents a process

Instance Methods | [hide private]
__init__(self, node=None, test_case=None) Constructs a Process associating it with a particualar TestScenario and Node | source code
get_args(self) Get the process 'user' arguments | source code
get_command(self) Get the process executable name | source code
get_log_file(self) Return the standard out / error log file name for this process that has been set explicitly or a suitable default otherwise. | source code
get_process_env(self) Return the env that this process should be spawned or run with. | source code
get_process_id_number(self) Return a unique number identifying this process instance within the test run. | source code
get_test_lib_args(self) Get the additional process args required to initialise the OSPL test lib interprocess synchronisation stuff (if required) You can of course do this 'manually' but this does it for you if you've stuck to the usual case. | source code
get_working_dir(self) Get the process working directory path. | source code
set_args(self, args) Set the process 'user' arguments | source code
set_command(self, command) Set the process executable name | source code
set_log_file(self, file_name) Set a log file name that is to be used for standard out and error collection for this process. | source code
set_uses_test_sync_lib(self, does_use_it=1) Set whether this process uses the test sync lib or not. | source code
set_working_dir(self, working_dir) Explicitly set the process working directory path. | source code

Method Details | [hide private]

### get_process_env(self) | source code
Return the env that this process should be spawned or run with. Adds the

### get_process_id_number(self) | source code
Return a unique number identifying this process instance within the test run. Handy as a key if starting asynchronously.

### get_working_dir(self) | source code
Get the process working directory path. Returns default for this TestScenario on this Process's Node

### set_log_file(self, file_name) | source code
Set a log file name that is to be used for standard out and error collection for this process. Will be created in the working directory. Take care to make this unique within this scenario if you don't want it to be overwritten.

### set_uses_test_sync_lib(self, does_use_it=1) | source code
Set whether this process uses the test sync lib or not. Default is true. Set to 0 to prevent STAX providing extra config args when this process is started.

### set_working_dir(self, working_dir) | source code
Explicitly set the process working directory path. Required if you don't want to take the default (which will be testsuite/tests/<scenario name> or whatever else has been set explicitly on the scenario