Setting up your basic test framework in soapUI is as easy as pointing it toward your web service's WSDL. Using the provided WSDL information, it can generate a test suite with test requests built on available operations.
The main soapUI window
To test each request, you can define a set of pass/fail assertions. SoapUI provides an impressive number of assertion types-- you can validate against response codes, confirm that responses are received within a set number of seconds, etc. Data validation includes simple Contains/Not Contains tests that check for the presence (or absence) of specific data in responses or more flexible XQuery and XPath assertions that allow you to parse and analyze response XML data to ensure it matches expected results.
I've found XQuery assertions particularly useful, especially when dealing with a mix of static and dynamic data in responses-- you can set up XQuery assertions in such a way that the static data (which is more suitable for automated verification) is isolated from the dynamic data and verify large data sets all at once.
It's also worth noting that a sister application for soapUI called loadUI was introduced within the last few years. As you might guess, loadUI is a tool for performing load tests against a web service. One of the selling points of loadUI is that you can use the same functional test requests developed in soapUI as your loadUI test requests.
Over the next few posts, I'll dig a little deeper into soapUI, including XQuery and XPath syntax for those who may not have worked with it before.
No comments:
Post a Comment
Please be respectful of others (myself included!) when posting comments. Unfortunately, I may not be able to address (or even read) all comments immediately, and I reserve the right to remove comments periodically to keep clutter to a minimum ("clean" posts that aren't disrespectful or off-topic should stay on the site for at least 30 days to give others a chance to read them). If you're looking for a solution to a particular issue, you're free to post your question here, but you may have better luck posting your question on the main forum belonging to your tool's home site (links to these are available on the navigation bar on the right).