Better Software - March 2009 - (Page 35) Table 1: Web service functional valid data table Table 2: Web service functional invalid data table We will use a Web service test tool and point the tool to the WSDL URL or location, enter the security settings (discussed later), and be presented with an input screen that looks similar to the XML request. The screen may have an edit box or a “?” giving us a specific place to enter our data table values. Press the Run button and, like magic, the response will appear for you to verify. This is very similar to Web testing, but now we are using an “editable” GUI interface and, instead of being navigated to another page or checking a value on the screen, we need to verify the XML response. Another tool that comes in handy for testing Web services is a file-comparison tool that allows you to compare the XML response to an expected XML file. We use the response fields in the data tables to verify field values, but we also want to verify that the complete XML schema is correct. This is very difficult to do by eye. To verify an XML schema, save the expected XML response file and compare it to the actual XML response file that you receive. There are many free file-comparison tools, and most Web service test tools have file-comparison functionality built in. Web service testing tools come in many different flavors, each with its own unique features. Some tools have features that assist in interacting with the Web services and include wizards that automatically create sample requests and GUI text boxes to enable you to enter required data easily into the XML request. Some tools create a “mock service” or stub allowing you to build functional tests before the actual Web service is ready. Other tool features assist in building a test architecture or framework for data-driving tests, calculating WSDL and requirements coverage, and organizing test suites and test cases, as well www.StickyMinds.com as complete test-execution reports. Most tools include functionality to test WSDL .NET and Java compliance, XML response verification, and XML schema verification. If you are investigating Web service testing tools, you may want to consider the following sites that have Web services you can use to assess the capabilities and GUI presentation of different tools: Xmethods www.xmethods.net/ve2/Directory.po WebServiceX.net www.webservicex.net/WCF/default.aspx These sites allow you to access a variety of different types of Web services that have been developed using different languages, methods, and toolkits. These provide you with a “testing ground” to investigate a tool’s look, feel, and functionality and a place to test out the tool’s features. MARCH 2009 BETTER SOFTWARE 35 http://www.xmethods.net/ve2/Directory.po http://www.WebServiceX.net http://www.webservicex.net/WCF/default.aspx http://www.StickyMinds.com
For optimal viewing of this digital publication, please enable JavaScript and then refresh the page. If you would like to try to load the digital publication without using Flash Player detection, please click here.