Clear_Capital__
12 years agoContributor
groovy - remove first and last line of a xml
def ResponseXML = context.expand( '${myRESTtestStep#ResponseAsXml#//Response[1]/e[1]}' )
gives me
<e>
<distance>0.44</distance>
<id>123456</id>
<value>
<Count1>2</Count1 >
<Count2>3</Count2>
</value>
</e>
I need to be able to remove first and lines, <e> and </e> , such that I get following value
<distance>0.44</distance>
<id>123456</id>
<value>
<Count1>2</Count1 >
<Count2>3</Count2>
</value>
Please let me know how would I do that ?
Thank you
gives me
<e>
<distance>0.44</distance>
<id>123456</id>
<value>
<Count1>2</Count1 >
<Count2>3</Count2>
</value>
</e>
I need to be able to remove first and lines, <e> and </e> , such that I get following value
<distance>0.44</distance>
<id>123456</id>
<value>
<Count1>2</Count1 >
<Count2>3</Count2>
</value>
Please let me know how would I do that ?
Thank you