Forum Discussion

andrew_laser's avatar
andrew_laser
Occasional Contributor
13 years ago

groovyUtils.getXmlHolder() exceptions in "Setup Script"

The following code executed in the test case's "Setup Script" causes error popup in the second line
"Request1" is the name of the step I want to process


def groovyUtils = new com.eviware.soapui.support.GroovyUtils( context )
def holder = groovyUtils.getXmlHolder("Request1#Request" )



org.apache.xmlbeans.XmlException: error: Unexpected element: CDATA


Can anybody figure out what is wrong?

I'm trying to get the holder in order to modify my Request.
NOTE: Property expansion is not suitable for me, because of test case logic.

The request XML is attached.

3 Replies

  • kondasamy's avatar
    kondasamy
    Regular Contributor

    Hi,

     

    I guess some thing is wrong with the request XML. Please check whether the <SUNIT> tag correctly ends.

     

    error on line 5 at column 36: Opening and ending tag mismatch: SUNIT line 0 and UNIT

    Thanks,

    Samy

  • bhavikkp's avatar
    bhavikkp
    Occasional Contributor

    I am also facing the same problem .

     

    Can you please help me out on this issue so I can move forward with GroovyScripting

     

    • nmrao's avatar
      nmrao
      Champion Level 3

      1

      Selection_258.png

       

      The request is invalid, correct it. Then you should be able to see the xml properly when open it in the brower.