MantisBT - TestLink
View Issue Details
0005857TestLinkAPI - XMLRPCpublic2013-08-14 13:312013-09-08 17:53
radoslaw.sporny 
fman 
normalminoralways
closedfixed 
1.9.7 (2013 Q2 - bug fixing) 
1.9.8 (2013 Q3 - bug fixing) 
MySQL
READY FOR TESTING
0005857: getTestCase() method with specified 'version' param always return version 1
When you call XMLRPC API method getTestCase() with 'version' parameter it always returns version 1.

It may cause unexpected failures. For example, TC-1 has version 2 and 3, but version 1 was deleted. When you call getTestCase() with specified 'version' param (let's say that you want 2) it returns error message "(getTestCase) - No Test Case found for search criteria". In that case there is no way to get TC-1 in version 2.
1. Call getTestCase('testcaseid', 'version').

Example request:
<?xml version="1.0" encoding="ISO-8859-1"?>
<methodCall>
   <methodName>tl.getTestCase</methodName>
   <struct>
      <devKey>
         <name>devKey</name>
         <value><string>your.dev.key</string></value>
      </devKey>
      <testcaseid>
         <name>testcaseid</name>
         <value><int>tc.internal.id</int></value>
      </testcaseid>
      <version>
         <name>version</name>
         <value><int>2</int></value>
      </version>
   </struct>
</methodCall>
No tags attached.
child of 0005731closed fman Availables hot-fixes for 1.9.7 & How To get full fixed package from gitorious 
Issue History
2013-08-14 13:31radoslaw.spornyNew Issue
2013-08-14 13:44fmanAssigned To => fman
2013-08-14 13:44fmanStatusnew => acknowledged
2013-08-14 14:02fmanNote Added: 0019420
2013-08-14 14:02fmanQA Team - Task Workflow StatusTBD => READY FOR TESTING
2013-08-14 14:02fmanStatusacknowledged => resolved
2013-08-14 14:02fmanFixed in Version => 1.9.8 (2013 Q3 - bug fixing)
2013-08-14 14:02fmanResolutionopen => fixed
2013-08-14 14:04fmanRelationship addedchild of 0005731
2013-08-14 14:38radoslaw.spornyNote Added: 0019421
2013-09-08 17:53fmanNote Added: 0019525
2013-09-08 17:53fmanStatusresolved => closed

Notes
(0019420)
fman   
2013-08-14 14:02   
quick fix

Original
$result = $testCaseMgr->get_by_id($id,$version_id,'ALL','ALL',$version_number);
    

Replace with
$filters = array('active_status' => 'ALL', 'open_status' => 'ALL', 'version_number' => $version_number);

    $result = $testCaseMgr->get_by_id($id,$version_id,$filters);
(0019421)
radoslaw.sporny   
2013-08-14 14:38   
works very well for me - thanks for fast response!
(0019525)
fman   
2013-09-08 17:53   
1.9.8 released