It's all about the answers!

Ask a question

How can RQM Execution Variables be created in a testscript via the REST API?


Paul Spalitta (8143037) | asked Jun 24 '14, 12:46 p.m.
edited Jun 24 '14, 1:38 p.m.
Hello,

We want to create test scripts through the REST API with Execution Variables setup. How can we do that? 

Execution Variables show-up in the XML when using GET on a Test Script that already contains Execution Variables, but if that same XML is then PUT back to RQM the Execution Variable info is not retained and Set Execution Variable steps are just "execution" steps.

Note: We are using RQM 4.0.3.

Thanks,

Paul

One answer



permanent link
Reshma Ratnani (1.1k1) | answered Jun 25 '14, 4:45 a.m.
JAZZ DEVELOPER
Hi Paul,

What is the syntax of the execution variable xml you are using. Try below syntax

 <ns2:variables>
    <ns2:variable>
      <ns2:name>exec var1</ns2:name>
      <ns2:value>exec val1</ns2:value>
    </ns2:variable>
    <ns2:variable>
      <ns2:name>exec var2</ns2:name>
      <ns2:value>exec val2</ns2:value>
    </ns2:variable>
 </ns2:variables>

Thanks

Comments
Paul Spalitta commented Jun 25 '14, 10:47 a.m.
Hi Reshma,

Thank you for response. We are trying to work with Set Execution Variable steps in manual test scripts. We do not want to define a value for the Execution Variable prior to the execution of the test.

So we are using the following XML to create the Execution Variables and they are created just fine: 

<ns2:variables>
  <ns2:variable>
   <ns2:name>XYZ</ns2:name>
  </ns2:variable>
</ns2:variables>

The problem we are having is with the Set Execution Variable step. For some reason it gets created as "type=execution" instead of "type=variable".

Thanks,

Paul

Paul Spalitta commented Jun 25 '14, 10:50 a.m.
We are using the following XML for the Set Execution Variable step:

<ns9:step ns3:id="_OGy6gPu8EeO0FZaipMXvkg" type="variable" stepIndex="5">
  <ns9:name>Set �XYZ� </ns9:name>
  <ns9:title>Set �XYZ� </ns9:title>
  <ns9:description>
    <div:div xmlns:div="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml" xmlns:o="urn://schemas-microsoft-com:office:office" xmlns:st1="urn://schemas-microsoft-com:office:smarttags" xmlns:v="urn://schemas-microsoft-com:vml" xmlns:w="urn://schemas-microsoft-com:office:word">Set  <button class="executionVariable" disabled="true" id="XYZ" name="ExecVariable" style="color: #000000; background-color: #FDE3B9;" type="button">XYZ</button> </div:div>
  </ns9:description>
  <ns9:expectedResult/>
</ns9:step>

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.