1. Create a test from your WSDL request
Click the plus sign next to the navigation to expand the project tree's Web service and select Request:
In Soapui Pro, the requested edit appears on the right. SoapUI Pro has an editor that simplifies the hierarchical structure of XML, both in request and in response, and is customizable in real time.
Learn more about the form editor and the outline editor.
If you are using the Soapui free version, you must manually enter the data in the Code Editor as shown below. In order to fully benefit from this tutorial, you should use the Professional edition.
2. In the request editor, select Add this request to TestCase. The definition of the request is accepted in Soapui, allowing you to enter the information manually. This is especially useful when doing manual testing, or you want a non-technician to perform a network request test.
3. Adding a request to the test case opens the Create TestSuite dialog box. Enter a name for your testsuite, and then click OK.
4. When you click OK, you will be asked to create a testcase. In the Create a TestCase dialog box, enter your TestCase name, and then click OK.
5. Next, the dialog box Add Request to TestCase will appear. Click OK.
6. When the request is created as TESTREQUESTB, SOAPUI will automatically generate a testsuite and testcase for you. The following is a copy of the request that appears on the interface.
The next step is to verify the response of the test by asserting the assertion.
2. Add an assertion test
Now that we've created and run our first Test, we're going to add a response to the validation. In Soapui, this is called adding assertions . The SOAPUI contains a variety of features that enhance automated, repetitive testing, requiring a large number of assertions.
Some examples of assertions:
- Schema Compliance
- Simple Contains
- Simple Not Contains
- SOAP Fault
- Not SOAP Fault
- SOAP Response
- Response SLA
- XPath Match
- XQuery Match
- Script Assertion
- Ws-security Status
- Ws-addressing Response Assertion
- Ws-addressing Request Assertion
1. You double-click the previously created Test Request as shown in. This opens the request editor.
2. In the editor, click the Add an assertion to Test Request button.
3. Select the SLA dialog box from the Select Assertion menu.
4. In the Configure Response SLA Assertion dialog box, fill in 500, then click OK. This verifies that the SLA response is more than 500ms (milliseconds).
5. Now that you have added the assertion, you want to run the validation response that should be requested. If all assertions are successful, the soap icon should be turned green in three places, as shown in.
6. You can also verify the assertion by adding a response to the XPath Match .
7. In Soapui, you can open the Select XPath dialog box and let you select the node assertion. This soapui creates an XPath expression that matches the node that points to the selection.
8. Soapui automatically fills in matching XPath results. Of course, you can change the associated XPath expression.
9. Now, let's try to enter the Fromcurrency SEK(Swedish krona) and tocurrency USD (for USD) requests and perform the tests.
10. Now, you will see that all assertions are "valid".
Now that you know what assertions are and how to add a test, it's time for the final exam for this guide-run the actual test.
3. Run the test
You can try to run the testcase from the TestCase editor ...
... or from the Testsuite editor.
SOAPUI Chinese operation manual (ii)----Create a test from your WSDL request