如何在soapUI Groovy中提取body标记内的soap响应
我有这样的反应如何在soapUI Groovy中提取body标记内的soap响应,groovy,soapui,Groovy,Soapui,我有这样的反应 <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Body> <ns3:ResponseElement xmlns:ns2="http://www.example.com/services/common/example/xsd" xmlns:ns3="http://www.example.com/example/xsd">
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<ns3:ResponseElement xmlns:ns2="http://www.example.com/services/common/example/xsd" xmlns:ns3="http://www.example.com/example/xsd">
<Info>
<Data>
<Site>OneValue</Site>
</Data>
<OtherData>
<Code>56789</Code>
<Time>2017-07-30</Time>
<SecondCode>ThirdValue</SecondCode>
<Number>111</Number>
</OtherData>
</Info>
</ns3:ResponseElement>
</S:Body>
</S:Envelope>
在groovy中,如何将响应提取为
标记中的XML?我找到了答案。如果寻找这个,它可能会帮助其他人
def body = context.expand('${TestStepName#Response#//soap:Body}')
log.info body