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.

How to use csv, excel, xml data source in subsequent SOA test while allow altercation in XML

Options
Pattu
Pattu Posts: 49
  1. I have to run query against a data base and fetch a top 1 XML and save it locally
  2. Few fields inside that XML [saved in local ] will need to be changed [ basically parameterized] so that a new xml with new values will be generated for further validation
  3. Now i took a random top1 XML based on query criteria, when i used this in SOA test , it allows me to alter the values which I want exactly , however it says save expected XML where will it get saved?
  4. how to use that latest saved altered xml in subsequent tests , example i have highlighted in screen shot .

Comments

  • benken_parasoft
    benken_parasoft Posts: 1,356 ✭✭✭

    "Alter" is used to made modifications to text nodes prior to extractions being done. In a XML Transformer, this can affect what is sent to the "Transformed XML" output. In a XML Data Bank, this can affect the values you are saving to data bank columns.

    "Save expected XML" affects whether the XML document you are currently seeing in the tool settings is saved as part of the tool configuration. If not saved then you won't see any XML document there if you were to close then re-open the tst file. It has nothing to do with "Allow alteration".

  • Pattu
    Pattu Posts: 49

    so what is the suggestion here ? any use case explanation please?

  • benken_parasoft
    benken_parasoft Posts: 1,356 ✭✭✭
    edited June 23

    It sounds like you are trying to use the "Alter" tab to modify and parameterize fields prior to extraction. This does indeed work. After adding a field to the "Alter" tab you can click "Modify". Next, in the "Alteration" settings you can select "Replace" then set the "Value" field to "Parameterized".