Create manual test cases for web services
Each operation in each Web service needs to have test cases. Since Web services do not have a GUI that may look different, or different buttons to do different things depending on which button you press (for example, Cancel, Save), so it is appropriate to build test cases other than ordinary e.g. web applications. In Web services there is an xml file that is sent (the request) and then another xml file come back in the response. What differs between each call is the data sent and the data received - a call may contain many different parameters and a response may contain many different parameters. What then becomes important to handle well in testing of Web services is the test data.
One example is a service that looks up the weather on a given location. Let us say that the service takes the following parameters:
• Date
• Time
• Location
• The forecast length (we have forecasts for twenty-two days, etc.)
• Language (we want answers in Swedish, English, Spanish, etc.)
There are of course many possible parameters, but we are satisfied with this. Our test data will then handle different date, different time, different locations, different lengths of the projections and the different languages of the answer. Our test data must also deal with negative test cases for example when we do not send in any dates, or the wrong format in date, or do not specify an existing site or existing language. In order to test different scenarios need when test data are presented showing both the parameters and expected response parameters.
Examples of very simple form:
Request
<? xml version = "1.0"?>
<soap: Envelope
xmlns: soap = "http://schemas.xmlsoap.org/soap/envelope"
soap: encodingStyle = "http://www.w3.org/2003/05/soap-encoding">
<soap:Body xmlns:m="http://www.dinsite.org/client">
<m:GetWeather>
<m:Location> Paris </ m: Location>
<m:Date> 2009-04-09 </ m: date>
<m:Time> 12:00 </ m: Time>
<m:Lenght> 3 </ m: Length>
<m:Language> Eng </ m: language>
</ m: GetWeather>
</ soap: Body>
</ soap: Envelope>
Response
<? xml version = "1.0"?>
<soap: Envelope
xmlns: soap = "http://schemas.xmlsoap.org/soap/envelope"
soap: encodingStyle = "http://www.w3.org/2003/05/soap-encoding">
<soap:Body xmlns:m="http://www.dinsite.org/client">
<m:GetWeatherResponse>
<m:Location> Paris </ m: Location>
<m:Forecast>
<m:Day1>
<m:Date> 2009-04-09 <m:Date>
<m:Weather> Rain <m:Weather>
</ m: Day1>
<m:Day2>
<m:Date> 2009-04-10 <m:Date>
<m:Weather> Super Much rain <m:Weather>
</ m: Day2>
<m:Day3>
<m:Date> 2009-04-11 <m:Date>
<m:Weather> Hurricane and rain <m:Weather>
</ m: Day3>
</ m: Forecast>
</ m: GetWeatherResponse>
</ soap: Body>
</ soap: Envelope>
It it not very clear and easy to to work with the test data inside the xml file it is better to use an excelsheet with the testdata. These sheets can then be used as a structured way to analyse test data and also as input parameters in automated regression testing after a little adjustment.

