Submit and vote on feature ideas.

Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.

Modify data bank in Method Tool

Options
LegacyForum
LegacyForum Posts: 1,664 ✭✭
edited December 2016 in SOAtest
Is there a way to directly modify a data bank (actually many of them) in the method tool (using Jython)? I know I can add a databank as an output tool, but this seems very indirect. I'm looking for something similar to MethodToolContext.getVariable(), which only returns test suite variables. Thanks.
Tagged:

Comments

  • LegacyForum
    LegacyForum Posts: 1,664 ✭✭
    Options
    Hi Kevin,

    The XML Data Bank only stores values, and once stored these values are not writable. However, you can alter values directly in the XML Data Bank by expanding the Options section at the bottom of the XML Data Bank Editor window, and enable Allow Alteration. Now, you can add an XPath to the Alter tab on the right, and double-click on it to set Alteration options.
    If you want to get the value that an XML Data Bank stores within a Method Too, you can use context.getValue(). For the Data Source name, use "Generated Data Source". This is a special Data Source name, and doesn't need to be specified with addDataSources().
  • LegacyForum
    LegacyForum Posts: 1,664 ✭✭
    Options
    the allow alterations option is a neat trick. I think it might come in handy.

Tagged