Testopia:Documentation:XMLRPC:TestCaseRun: Difference between revisions
(changed .create Result to reflect throwing of XmlRpcException vs. hashmap of faultcode/faultstring) |
(fixed on-error results info) |
||
Line 66: | Line 66: | ||
=====Result===== | =====Result===== | ||
A hash map of key/value pairs for the attributes listed above | A hash map of key/value pairs for the attributes listed above on success; on error, an XmlRpcException is thrown. | ||
=====Example===== | =====Example===== | ||
Line 92: | Line 92: | ||
=====Result===== | =====Result===== | ||
An array of TestCaseRun hash maps or a hash map containing values for the keys, | An array of TestCaseRun hash maps or a hash map containing values for the keys on success; on error, an XmlRpcException is thrown. | ||
=====Example===== | =====Example===== | ||
Line 120: | Line 120: | ||
=====Result===== | =====Result===== | ||
An integer value representing the new test case run id | An integer value representing the new test case run id on success; on error, an XmlRpcException is thrown. | ||
=====Example===== | =====Example===== | ||
Line 184: | Line 184: | ||
=====Result===== | =====Result===== | ||
An array of Bug hash maps or a hash map containing values for the keys, | An array of Bug hash maps or a hash map containing values for the keys on success; on error, an XmlRpcException is thrown. | ||
=====Example===== | =====Example===== | ||
Line 210: | Line 210: | ||
=====Result===== | =====Result===== | ||
The TestCaseRun status id for the respective name | The TestCaseRun status id for the respective name, empty string ('') if the name is not found. | ||
=====Example===== | =====Example===== | ||
Line 235: | Line 235: | ||
=====Result===== | =====Result===== | ||
The TestCaseRun status name for the respective id or | The TestCaseRun status name for the respective id or 0 error occurs. | ||
=====Example===== | =====Example===== |
Revision as of 21:33, 25 September 2007
Back to Testopia XML-RPC API
TestCaseRun
Description
A test case run is a record in the test_case_runs table which joins test cases to test runs. Basically, for each test run a selection of test cases is made to be included in that run. As a test run progresses, testers set statuses on each of the cases in the run.
Hiearchy
Bugzilla::WebService::Testopia::TestCaseRun
Attributes
Attribute | Data Type | Comments | Create | Read | Update |
assignee | integer | ID value | Required | X | X |
build_id | integer | Required | X | X | |
canview | integer | X | |||
case_id | integer | Required | X | ||
case_run_id | integer | X | |||
case_run_status_id | integer | X | |||
case_text_version | integer | Required | X | ||
close_date | string | Format: yyyy-mm-dd hh:mm:ss | X | ||
environment_id | integer | Required | X | ||
iscurrent | integer | X | |||
notes | string | Optional | X | X | |
run_id | integer | Required | X | ||
sortkey | integer | X | |||
testedby | integer | ID value | X |
Methods
get - Get A TestCaseRun by ID
Usage
TestCaseRun.get
Parameters
Parameter | Data Type | Comments |
case_run_id | integer | Must be greater than 0. |
Result
A hash map of key/value pairs for the attributes listed above on success; on error, an XmlRpcException is thrown.
Example
Perl
my $caserun_id = 1; my $result = $proxy->call("TestCaseRun.get", $caserun_id);
list - Get A List of TestCaseRuns Based on A Query
Usage
TestCaseRun.list
Parameters
Parameter | Data Type | Comments |
query | hashmap | Can not be null. See Query Examples. |
Result
An array of TestCaseRun hash maps or a hash map containing values for the keys on success; on error, an XmlRpcException is thrown.
Example
Perl
my $result = $proxy->call("TestCaseRun.list", {build_id => 1, case_id => 1});
create - Create A New TestCaseRun
Usage
TestCaseRun.create
Parameters
Parameter | Data Type | Comments |
new_values | hashmap | See required attributes list1 below. |
1 Required attributes: assignee, build_id, case_id, case_text_version, environment_id, and run_id
2 case_run_status_id always set to 1 (IDLE) on create
Result
An integer value representing the new test case run id on success; on error, an XmlRpcException is thrown.
Example
Perl
my $result = $proxy->call("TestCaseRun.list", {assignee => 1, build_id => 1, case_id => 1, case_text_version => 1, environment_id => 1, run_id => 1});
update - Update An Existing TestCaseRun
Usage
TestCaseRun.update
Parameters
Parameter | Data Type | Comments |
run_id | integer | |
case_id | integer | |
build_id | integer | |
environment_id | integer | |
new_values1,2 | hashmap | See attributes list modifiable fields. |
1 The notes attribute can be used to append a new note to the respective TestCaseRun.
2 To automatically update an attached bug's status, set the new_values attribute, update_bugs, to 1.
Result
The modified TestCaseRun on success; on failure, an XmlRpcException is thrown.
Example
Perl
my $result = $proxy->call("TestCaseRun.update", $run_id, $case_id, $build_id, $environment_id, {assignee => 1, caserun_status_id => 1, notes => 'Notes'});
get_bugs - Get a list of bugs for the given TestCaseRun
Usage
TestCaseRun.get_bugs
Parameters
Parameter | Data Type | Comments |
case_run_id | integer |
Result
An array of Bug hash maps or a hash map containing values for the keys on success; on error, an XmlRpcException is thrown.
Example
Perl
my $caserun_id; my $result = $proxy->call("TestCaseRun.get_bugs", $caserun_id);
lookup_status_id_by_name - Lookup A TestCaseRun Status ID By Its Name
Usage
TestCaseRun.lookup_status_id_by_name
Parameters
Parameter | Data Type | Comments |
name | string | Cannot be null or empty string |
Result
The TestCaseRun status id for the respective name, empty string () if the name is not found.
Example
Perl
my $result = $proxy->call('TestCaseRun.lookup_status_id_by_name', 'Name');
lookup_status_name_by_id - Lookup A TestCaseRun Status Name By Its ID
Usage
TestCaseRun.lookup_status_name_by_id
Parameters
Parameter | Data Type | Comments |
id | integer | Cannot be 0 |
Result
The TestCaseRun status name for the respective id or 0 error occurs.
Example
Perl
my $result = $proxy->call('TestCaseRun.lookup_status_name_by_id', 1);
Back to the Testopia Main Page