14 years ago
How to store response values into Excel using SoapUI?
Hi,
I am using SoapUI for automation testing using SOAP/HTTP. I want to store Soap response (xml) values into Excel for reporting purposes. Is there a way through Properties or Groovy to access the XML values and store them in Excel.
Eg: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<GetWeatherByPlaceNameResponse xmlns="http://www.webservicex.net">
<GetWeatherByPlaceNameResult>
<Latitude>30.6171017</Latitude>
<Longitude>99.62553</Longitude>
<AllocationFactor>2.7E-05</AllocationFactor>
<FipsCode>48</FipsCode>
<PlaceName>LONDON</PlaceName>
<StateCode>TX</StateCode>
<Details>
<WeatherData>
<Day>Thursday, June 16, 2011</Day>
<WeatherImage>http://forecast.weather.gov/images/wtf/sct.jpg</WeatherImage>
<MaxTemperatureF>100</MaxTemperatureF>
<MinTemperatureF>75</MinTemperatureF>
<MaxTemperatureC>38</MaxTemperatureC>
<MinTemperatureC>24</MinTemperatureC>
</WeatherData>
<WeatherData>
I want to store values of the following nodes in XL by accessing the response XML.
<MaxTemperatureF>100</MaxTemperatureF>
<MinTemperatureF>75</MinTemperatureF>
<MaxTemperatureC>38</MaxTemperatureC>
Please revert ASAP
I am using SoapUI for automation testing using SOAP/HTTP. I want to store Soap response (xml) values into Excel for reporting purposes. Is there a way through Properties or Groovy to access the XML values and store them in Excel.
Eg: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<GetWeatherByPlaceNameResponse xmlns="http://www.webservicex.net">
<GetWeatherByPlaceNameResult>
<Latitude>30.6171017</Latitude>
<Longitude>99.62553</Longitude>
<AllocationFactor>2.7E-05</AllocationFactor>
<FipsCode>48</FipsCode>
<PlaceName>LONDON</PlaceName>
<StateCode>TX</StateCode>
<Details>
<WeatherData>
<Day>Thursday, June 16, 2011</Day>
<WeatherImage>http://forecast.weather.gov/images/wtf/sct.jpg</WeatherImage>
<MaxTemperatureF>100</MaxTemperatureF>
<MinTemperatureF>75</MinTemperatureF>
<MaxTemperatureC>38</MaxTemperatureC>
<MinTemperatureC>24</MinTemperatureC>
</WeatherData>
<WeatherData>
I want to store values of the following nodes in XL by accessing the response XML.
<MaxTemperatureF>100</MaxTemperatureF>
<MinTemperatureF>75</MinTemperatureF>
<MaxTemperatureC>38</MaxTemperatureC>
Please revert ASAP