Forum Discussion

M_McDonald's avatar
M_McDonald
Super Contributor
16 years ago

Is there any way to entitize values within a property expansion?

I am using a DataSource to populate a Test Request. I know that I can turn on "Entitize Data Values" for the request, but I also need the un-entitized values later on for back-end validations. Is there any way I can perform the entity transformation within a property expansion?

Thanks.

3 Replies

  • Hi!

    Try disabling the "Entitize.." option in the DataSource and instead enable the "Entitize Properties" setting for the request (bottom left properties). Does that help you forward?

    regards!

    /Ole
    eviware.com
  • M_McDonald's avatar
    M_McDonald
    Super Contributor
    This works to a point, but I am embedding an XML fragment in the request with a property expansion, and turning on 'Entitize Properties' for the Request causes attribute value delimiters in the fragment to be entitized, eg.:

    [tt:2cq14upm][/tt:2cq14upm]

    becomes

    [tt:2cq14upm][/tt:2cq14upm]

    Similarly, double quotes around attribute values are changed to ".

    [tt:2cq14upm][/tt:2cq14upm]

    becomes

    [tt:2cq14upm][/tt:2cq14upm]

    Since the Entitize setting is for the whole request, there is no way to protect the XML fragment from what appears to be a simple search & replace.

    Perhaps for a future release you might consider extending property expansions, so for example ${& } would entitize the referenced property and ${! } would protect the property from any global entity replacement. This would provide finer grained control while not breaking existing functionality.