Testopia:Documentation:XMLRPC:TestCase: Difference between revisions

From MozillaWiki
Jump to navigation Jump to search
No edit summary
 
No edit summary
Line 13: Line 13:


{| border=1 cellpadding=4
{| border=1 cellpadding=4
| '''Attribute''' || '''Data Type''' || '''Comments'''  
| '''Attribute''' || '''Data Type''' || '''Comments''' || '''Create''' || '''Read''' || '''Update'''
|-
|-
| alias || string ||
| alias || string || || Optional || X || X
|-
|-
| arguments || string ||
| arguments || string || || Optional || X || X
|-
|-
| author || string ||
| author_id || integer || || Required || X ||  
|-
|-
| case_id || integer ||
| canview || integer || || || X ||
|-
| case_id || integer || || || X ||
|-
| case_status_id || integer || || Required || X || X
|-
| category_id || integer || || Required || X || X
|-
|-
| case_status || string ||
| creation_date || string || Format: yyyy-mm-dd hh:mm:ss || || X ||
|-
|-
| category || string ||
| default_tester_id || integer || || Optional || X ||
|-
|-
| creation_date || string || Format: yyyy-mm-dd hh:mm:ss
| isautomated || integer || || Required || X || X
|-
|-
| default_tester || string ||
| plans || Array of TestPlan hashmaps || || || X ||  
|-
|-
| isautomated || integer ||
| priority_id || integer || || Optional || X || X
|-
|-
| priority || string ||
| requirement || string || || Optional || X || X
|-
|-
| requirement || string ||
| script || string || || Optional || X || X
|-
|-
| script || string ||
| summary || string || || Required || X || X
|-
|-
| summary || string ||
| sortkey || integer || || Optional || X || X
|-
|-
| sortkey || string ||
| estimated_time || string || Format: hh:mm:ss || Optional || X || X
|-
|-
|}
|}
Line 67: Line 73:
A hash map of key/value pairs for the attributes listed above or a hash map containing values for the keys, "faultcode" and "faultstring".
A hash map of key/value pairs for the attributes listed above or a hash map containing values for the keys, "faultcode" and "faultstring".


 
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $result = $proxy->call('TestCase.get', $case_id);


----
----
====list - Get A List of TestCases Based on A Query====
====list - Get A List of TestCases Based on A Query====
----
----
Line 81: Line 89:
| '''Parameter''' || '''Data Type''' || '''Comments'''  
| '''Parameter''' || '''Data Type''' || '''Comments'''  
|-
|-
| query || string || Can not be null or an empty string.  See [[Bugzilla_XML-RPC_API_Query_Examples |Query Examples]].
| query<sup>1</sup> || hashmap || Can not be null.  See [[Bugzilla_XML-RPC_API_Query_Examples |Query Examples]].
|-
|-
|}
|}
<sup>1</sup>Other attributes available for use with query include: run_id




Line 89: Line 99:
An array of TestCase hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
An array of TestCase hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".


=====Example=====
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
Object[] result = (Object[]) client.execute("TestCase.list_components", params);
<b>Perl</b>
my $result = $proxy->('TestCase.list', {case_id => 1});


----
----
Line 105: Line 123:
|}
|}


<sup>1</sup> Required attributes: author, case_status, category, and isautomated.
<sup>1</sup> Required attributes: author_id, case_status_id, category_id, isautomated, and plan_id.




=====Result=====
=====Result=====
An integer value representing the new case_id or a hash map containing values for the keys, "faultcode" and "faultstring".
An integer value representing the new case_id or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
HashMap<String, Object> map = new HashMap<String, Object>();
map.put("arguments","");
map.put("case_status_id", "2"); //Can be Proposed (1), Disabled (3), Confirmed (2)
map.put("summary",summary);
map.put("script", script);
map.put("category","General");
map.put("isautomated","1");
map.put("category_id", category_id);
map.put("testedby", author_id);
map.put("author_id", author_id);
map.put("priority_id",priority_id);
map.put("plan_id", plan_id);
params.add(map);
Integer result = (Integer)client.execute("TestCase.create", params);
<b>Perl</b>
my $result = $proxy->call('TestCase.create', {summary => 'Summary', plan_id => 1, author_id => 1, isautomated => 0, category_id => 1, case_status_id => 2});




Line 126: Line 166:
| case_id || integer ||
| case_id || integer ||
|-
|-
| new_values || hashmap || case_id can not be modified.
| new_values || hashmap || author_id and case_id can not be modified.
|-
|-
|}
|}
Line 132: Line 172:


=====Result=====
=====Result=====
The integer value, 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".
The modified TestCase on success or a hash map containing values for the keys, "faultcode" and "faultstring".
 
=====Example=====
<b>Perl</b>
my $result = $proxy->call('TestCase.create', {summary => 'Summary', isautomated => 0, category_id => 1, case_status_id => 2,
                                              alias => 'Alias', arguments => 'Arguments', default_tester_id => 1,
                                              priority_id => 1, script => 'Script',  sortkey => 100,
                                              estimated_time => '12:12:12'});




Line 157: Line 204:
Attributes of a TestCase document are action, author, effect, and version.
Attributes of a TestCase document are action, author, effect, and version.


 
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $result = $proxy->call("TestCase.get_text", $case_id);


----
----
====set_text - Add A New TestCase Action/Effect Document====
====store_text - Add A New TestCase Action/Effect Document====
----
----


=====Usage=====
=====Usage=====
TestCase.set_text
TestCase.store_text


=====Parameters=====
=====Parameters=====
Line 172: Line 222:
| case_id || integer ||
| case_id || integer ||
|-
|-
| author || string ||
| author_id || integer ||
|-
|-
| action || string ||
| action || string ||
|-
|-
| effect || string ||
| effect || string ||
|-
| setup || string ||
|-
| breakdown || string ||
|-
|-
|}
|}
Line 184: Line 238:
The new document version on success or a hash map containing values for the keys, "faultcode" and "faultstring".
The new document version on success or a hash map containing values for the keys, "faultcode" and "faultstring".


=====Example=====
<b>Perl</b>
my $case_id = 1;
my $author_id = 1;
my $action = "New Action";
my $effect = "New Effect";
my $setup  = "New Setup";
my $breakdown = "New Breakdown";
my $result = $proxy->call("TestCase.store_text", $case_id, $author_id, $action, $effect, $setup, $breakdown);
----
====get_bugs - Get a list of bugs for the given TestCase====
----
=====Usage=====
TestCase.get_bugs
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
|}
=====Result=====
An array of Bug hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id;
my $result = $proxy->call("TestCase.get_bugs", $case_id);
----
====add_component - Add a component to the given TestCase====
----
=====Usage=====
TestCase.add_component
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| component_id || integer ||
|-
|}
=====Result=====
The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
params.add(component_id);
Integer result = (Integer)client.execute("TestCase.add_component", params);
<b>Perl</b>
my $case_id = 1;
my $component_id = 1;
my $result = $proxy->call('TestCase.add_component', $case_id, $component_id);
----
====remove_component - Remove a component from the given TestCase====
----
=====Usage=====
TestCase.remove_component
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| component_id || integer ||
|-
|}
=====Result=====
The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $component_id = 1;
my $result = $proxy->call('TestCase.remove_component', $case_id, $component_id);
----
====get_components - Get a list of components for the given TestCase====
----
=====Usage=====
TestCase.get_components
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
|}
=====Result=====
An array of Component hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $result = $proxy->call("TestCase.get_components", $case_id);
----
====add_tag - Add a tag to the given TestCase====
----
=====Usage=====
TestCase.add_tag
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| tag_name || string || Creates tag if it does not exist
|-
|}
=====Result=====
The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
params.add(tag_name);
Integer result = (Integer)client.execute("TestCase.add_tag", params);
<b>Perl</b>
my $case_id = 1;
my $tag_name = "Tag Name to Add";
my $result = $proxy->call("TestCase.add_tag", $case_id, $tag_name);
----
====remove_tag - Remove a tag from the given TestCase====
----
=====Usage=====
TestCase.remove_tag
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| tag_name || string ||
|-
|}
=====Result=====
The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $tag_name = "Tag Name to Remove";
my $result = $proxy->call("TestCase.remove_tag", $case_id, $tag_name);
----
====get_tags - Get a list of tags for the given TestCase====
----
=====Usage=====
TestCase.get_tags
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
|}
=====Result=====
An array of Tag hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $result = $proxy->call("TestCase.get_tags", $case_id);
----
====get_plans - Get a list of TestPlans for the given TestCase====
----
=====Usage=====
TestCase.get_plans
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
|}
=====Result=====
An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $result = $proxy->call("TestCase.get_plans", $case_id);
----
====lookup_category_id_by_name - Lookup A TestCase Category ID By Its Name====
----
=====Usage=====
TestCase.lookup_category_id_by_name
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| name || string || Cannot be null or empty string
|-
|}
=====Result=====
The TestCase category id for the respective name or 0 if an error occurs.
=====Example=====
<b>Perl</b>
my $category_name = 'Name';
my $result = $proxy->call('TestCase.lookup_category_id_by_name', $category_name);
----
====lookup_category_name_by_id - Lookup A TestCase Category Name By Its ID====
----
=====Usage=====
TestCase.lookup_category_name_by_id
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| id || integer || Cannot be 0
|-
|}
=====Result=====
The TestCase category name for the respective id or empty string if an error occurs.
=====Example=====
<b>Perl</b>
my $category_id = 1;
my $result = $proxy->call('TestCase.lookup_category_name_by_id', $category_id);
----
====lookup_priority_id_by_name - Lookup A TestCase Priority ID By Its Name====
----
=====Usage=====
TestCase.lookup_priority_id_by_name
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| name || string || Cannot be null or empty string
|-
|}
=====Result=====
The TestCase priority id for the respective name or 0 if an error occurs.
=====Example=====
<b>Perl</b>
my $priority_name = 'Name';
my $result = $proxy->call('TestCase.lookup_priority_id_by_name', $priority_name);
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
params.add(priority_name);
Integer result = (Integer)client.execute("TestCase.lookup_priority_id_by_name", params);
----
====lookup_priority_name_by_id - Lookup A TestCase Priority Name By Its ID====
----
=====Usage=====
TestCase.lookup_priority_name_by_id
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| id || integer || Cannot be 0
|-
|}
=====Result=====
The TestCase priority name for the respective id or empty string if an error occurs.
=====Example=====
<b>Perl</b>
my $priority_id = 1;
my $result = $proxy->call('TestCase.lookup_priority_name_by_id', $priority_id);
<b>Java</b>
ArrayList<Object> params = new ArrayList<Object>();
params.add(priority_id);
Integer result = (Integer)client.execute("TestCase.lookup_priority_name_by_id", params);
----
====lookup_status_id_by_name - Lookup A TestCase Status ID By Its Name====
----
=====Usage=====
TestCase.lookup_status_id_by_name
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| name || string || Cannot be null or empty string
|-
|}
=====Result=====
The TestCase status id for the respective name or 0 if an error occurs.
=====Example=====
<b>Perl</b>
my $status_name = 'Name';
my $result = $proxy->call('TestCase.lookup_status_id_by_name', $status_name);
----
====lookup_status_name_by_id - Lookup A TestCase Status Name By Its ID====
----
=====Usage=====
TestCase.lookup_status_name_by_id
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| id || integer || Cannot be 0
|-
|}
=====Result=====
The TestCase status name for the respective id or empty string if an error occurs.
=====Example=====
<b>Perl</b>
my $status_id = 1;
my $result = $proxy->call('TestCase.lookup_status_name_by_id', $status_id);
----
====link_plan - Link A TestPlan To An Existing TestCase====
----
=====Usage=====
TestCase.link_plan
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| plan_id || integer ||
|}
=====Result=====
An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $plan_id = 1;
my $result = $proxy->call('TestCase.link_plan', $case_id, $plan_id);
----
====unlink_plan - Unlink A TestPlan From An Existing TestCase====
----
=====Usage=====
TestCase.unlink_plan
=====Parameters=====
{| border=1 cellpadding=4
| '''Parameter''' || '''Data Type''' || '''Comments'''
|-
| case_id || integer ||
|-
| plan_id || integer ||
|}
=====Result=====
An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".
=====Example=====
<b>Perl</b>
my $case_id = 1;
my $plan_id = 1;
my $result = $proxy->call('TestCase.unlink_plan', $case_id, $plan_id);




<br>Back to the [[Testopia |Testopia Main Page]]
<br>Back to the [[Testopia |Testopia Main Page]]

Revision as of 20:55, 25 September 2007

Back to Testopia XML-RPC API

TestCase

Description

Each test case must be linked to one or more test plans.

Hiearchy

Bugzilla::WebService::Testopia::TestCase

Attributes

Attribute Data Type Comments Create Read Update
alias string Optional X X
arguments string Optional X X
author_id integer Required X
canview integer X
case_id integer X
case_status_id integer Required X X
category_id integer Required X X
creation_date string Format: yyyy-mm-dd hh:mm:ss X
default_tester_id integer Optional X
isautomated integer Required X X
plans Array of TestPlan hashmaps X
priority_id integer Optional X X
requirement string Optional X X
script string Optional X X
summary string Required X X
sortkey integer Optional X X
estimated_time string Format: hh:mm:ss Optional X X


Methods


get - Get A TestCase by ID


Usage

TestCase.get

Parameters
Parameter Data Type Comments
case_id integer Must be greater than 0.


Result

A hash map of key/value pairs for the attributes listed above or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $result = $proxy->call('TestCase.get', $case_id);

list - Get A List of TestCases Based on A Query


Usage

TestCase.list

Parameters
Parameter Data Type Comments
query1 hashmap Can not be null. See Query Examples.

1Other attributes available for use with query include: run_id


Result

An array of TestCase hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Java

ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
Object[] result = (Object[]) client.execute("TestCase.list_components", params);

Perl

my $result = $proxy->('TestCase.list', {case_id => 1});

create - Create A New TestCase


Usage

TestCase.create

Parameters
Parameter Data Type Comments
new_values hashmap See required attributes list1 below.

1 Required attributes: author_id, case_status_id, category_id, isautomated, and plan_id.


Result

An integer value representing the new case_id or a hash map containing values for the keys, "faultcode" and "faultstring".


Example

Java

ArrayList<Object> params = new ArrayList<Object>();
HashMap<String, Object> map = new HashMap<String, Object>();
map.put("arguments","");
map.put("case_status_id", "2"); //Can be Proposed (1), Disabled (3), Confirmed (2)
map.put("summary",summary);
map.put("script", script);
map.put("category","General");
map.put("isautomated","1");
map.put("category_id", category_id);
map.put("testedby", author_id);
map.put("author_id", author_id);
map.put("priority_id",priority_id);
map.put("plan_id", plan_id);
params.add(map);
Integer result = (Integer)client.execute("TestCase.create", params);

Perl

my $result = $proxy->call('TestCase.create', {summary => 'Summary', plan_id => 1, author_id => 1, isautomated => 0, category_id => 1, case_status_id => 2});



update - Update An Existing TestCase


Usage

TestCase.update

Parameters
Parameter Data Type Comments
case_id integer
new_values hashmap author_id and case_id can not be modified.


Result

The modified TestCase on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $result = $proxy->call('TestCase.create', {summary => 'Summary', isautomated => 0, category_id => 1, case_status_id => 2, 
                                              alias => 'Alias', arguments => 'Arguments', default_tester_id => 1, 
                                              priority_id => 1, script => 'Script',  sortkey => 100, 
                                              estimated_time => '12:12:12'});



get_text - Get TestCase's Current Action/Effect Document


Usage

TestCase.get_text

Parameters
Parameter Data Type Comments
case_id integer


Result

A hash map of key/value pairs for the attributes of a TestCase document or a hash map containing values for the keys, "faultcode" and "faultstring".

Attributes of a TestCase document are action, author, effect, and version.

Example

Perl

my $case_id = 1;
my $result = $proxy->call("TestCase.get_text", $case_id);

store_text - Add A New TestCase Action/Effect Document


Usage

TestCase.store_text

Parameters
Parameter Data Type Comments
case_id integer
author_id integer
action string
effect string
setup string
breakdown string


Result

The new document version on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $author_id = 1;
my $action = "New Action";
my $effect = "New Effect";
my $setup  = "New Setup";
my $breakdown = "New Breakdown";
my $result = $proxy->call("TestCase.store_text", $case_id, $author_id, $action, $effect, $setup, $breakdown);

get_bugs - Get a list of bugs for the given TestCase


Usage

TestCase.get_bugs

Parameters
Parameter Data Type Comments
case_id integer


Result

An array of Bug hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id;
my $result = $proxy->call("TestCase.get_bugs", $case_id);

add_component - Add a component to the given TestCase


Usage

TestCase.add_component

Parameters
Parameter Data Type Comments
case_id integer
component_id integer


Result

The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Java

ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
params.add(component_id);
Integer result = (Integer)client.execute("TestCase.add_component", params);

Perl

my $case_id = 1;
my $component_id = 1;
my $result = $proxy->call('TestCase.add_component', $case_id, $component_id);

remove_component - Remove a component from the given TestCase


Usage

TestCase.remove_component

Parameters
Parameter Data Type Comments
case_id integer
component_id integer


Result

The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $component_id = 1;
my $result = $proxy->call('TestCase.remove_component', $case_id, $component_id);



get_components - Get a list of components for the given TestCase


Usage

TestCase.get_components

Parameters
Parameter Data Type Comments
case_id integer


Result

An array of Component hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $result = $proxy->call("TestCase.get_components", $case_id);



add_tag - Add a tag to the given TestCase


Usage

TestCase.add_tag

Parameters
Parameter Data Type Comments
case_id integer
tag_name string Creates tag if it does not exist


Result

The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Java

ArrayList<Object> params = new ArrayList<Object>();
params.add(testCase_id);
params.add(tag_name);
Integer result = (Integer)client.execute("TestCase.add_tag", params);

Perl

my $case_id = 1;
my $tag_name = "Tag Name to Add";
my $result = $proxy->call("TestCase.add_tag", $case_id, $tag_name);



remove_tag - Remove a tag from the given TestCase


Usage

TestCase.remove_tag

Parameters
Parameter Data Type Comments
case_id integer
tag_name string


Result

The integer , 0, on success or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $tag_name = "Tag Name to Remove";
my $result = $proxy->call("TestCase.remove_tag", $case_id, $tag_name);



get_tags - Get a list of tags for the given TestCase


Usage

TestCase.get_tags

Parameters
Parameter Data Type Comments
case_id integer


Result

An array of Tag hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $result = $proxy->call("TestCase.get_tags", $case_id);



get_plans - Get a list of TestPlans for the given TestCase


Usage

TestCase.get_plans

Parameters
Parameter Data Type Comments
case_id integer


Result

An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $result = $proxy->call("TestCase.get_plans", $case_id);



lookup_category_id_by_name - Lookup A TestCase Category ID By Its Name


Usage

TestCase.lookup_category_id_by_name

Parameters
Parameter Data Type Comments
name string Cannot be null or empty string


Result

The TestCase category id for the respective name or 0 if an error occurs.

Example

Perl

my $category_name = 'Name';
my $result = $proxy->call('TestCase.lookup_category_id_by_name', $category_name);



lookup_category_name_by_id - Lookup A TestCase Category Name By Its ID


Usage

TestCase.lookup_category_name_by_id

Parameters
Parameter Data Type Comments
id integer Cannot be 0


Result

The TestCase category name for the respective id or empty string if an error occurs.

Example

Perl

my $category_id = 1;
my $result = $proxy->call('TestCase.lookup_category_name_by_id', $category_id);



lookup_priority_id_by_name - Lookup A TestCase Priority ID By Its Name


Usage

TestCase.lookup_priority_id_by_name

Parameters
Parameter Data Type Comments
name string Cannot be null or empty string


Result

The TestCase priority id for the respective name or 0 if an error occurs.

Example

Perl

my $priority_name = 'Name';
my $result = $proxy->call('TestCase.lookup_priority_id_by_name', $priority_name);

Java

ArrayList<Object> params = new ArrayList<Object>();
params.add(priority_name);
Integer result = (Integer)client.execute("TestCase.lookup_priority_id_by_name", params);

lookup_priority_name_by_id - Lookup A TestCase Priority Name By Its ID


Usage

TestCase.lookup_priority_name_by_id

Parameters
Parameter Data Type Comments
id integer Cannot be 0


Result

The TestCase priority name for the respective id or empty string if an error occurs.

Example

Perl

my $priority_id = 1;
my $result = $proxy->call('TestCase.lookup_priority_name_by_id', $priority_id);

Java

ArrayList<Object> params = new ArrayList<Object>();
params.add(priority_id);
Integer result = (Integer)client.execute("TestCase.lookup_priority_name_by_id", params);

lookup_status_id_by_name - Lookup A TestCase Status ID By Its Name


Usage

TestCase.lookup_status_id_by_name

Parameters
Parameter Data Type Comments
name string Cannot be null or empty string


Result

The TestCase status id for the respective name or 0 if an error occurs.

Example

Perl

my $status_name = 'Name';
my $result = $proxy->call('TestCase.lookup_status_id_by_name', $status_name);



lookup_status_name_by_id - Lookup A TestCase Status Name By Its ID


Usage

TestCase.lookup_status_name_by_id

Parameters
Parameter Data Type Comments
id integer Cannot be 0


Result

The TestCase status name for the respective id or empty string if an error occurs.

Example

Perl

my $status_id = 1;
my $result = $proxy->call('TestCase.lookup_status_name_by_id', $status_id);



link_plan - Link A TestPlan To An Existing TestCase


Usage

TestCase.link_plan

Parameters
Parameter Data Type Comments
case_id integer
plan_id integer


Result

An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $plan_id = 1;
my $result = $proxy->call('TestCase.link_plan', $case_id, $plan_id);



unlink_plan - Unlink A TestPlan From An Existing TestCase


Usage

TestCase.unlink_plan

Parameters
Parameter Data Type Comments
case_id integer
plan_id integer


Result

An array of TestPlan hash maps or a hash map containing values for the keys, "faultcode" and "faultstring".

Example

Perl

my $case_id = 1;
my $plan_id = 1;
my $result = $proxy->call('TestCase.unlink_plan', $case_id, $plan_id);



Back to the Testopia Main Page