Professional Documents
Culture Documents
Congratulations, youve just created your first soapUI Project. Lets add a WSDL.
Note: If you would like to try importing a project, try importing the Sample soapUI Project, see
[Web Service sample project] for more details.
2) Add a WSDL
In soapUI the projects mostly are based on a WSDL. Its not necessary to start by importing
a WSDL, but it makes testing easier since the WSDL contains all information you need about
the web service tested; information about the requests and responses, what they contain and
much more, which simplifies soapUI testing greatly.
Lets add a WSDL to the project;
1. Right click on the project node and select Add WSDL
Click OK.
3. You should now see that the WSDL was successfully added to the project by seeing the
Project Window.
5. You can also double click the Interface for an Interface view, which shows a lot of
information about the WSDL itself. This is very useful for browsing and examining a
WSDL.
2. A New LoadTest Dialog will open. In it, enter the name of your LoadTest and click OK.
The LoadTest will open.Don
1. Modify these values as desired (read more about soapUI LoadTest Configuration) and
2. run the test.
You will see the statistics table in the middle beginning collecting data and after 60
seconds should have a finished LoadTest. (read more about LoadTest Execution)
We have now succesfully run our first LoadTest, lets add an assertion to do Load Validations.
1. In the LoadTest editor, select the LoadTest Assertion tab at the bottom of the editor
3. The Add Assertion dialog will now open, select Step Maximum. Select Maximum sets a
Max Time in milliseconds that the responses are allowed to take, if the time exceeds what
weve set, the test will fail. Click OK.
4. The TestStep Max Assertion window will now open. As you can see we allow a max
response of one second, 1000 milliseconds. Lets not modify anyting, Click Ok
6. Now run the test again. You should see that the column err adds up quickly, the responses
takes to long time.
Basics
A LoadTest in soapUI is used for asserting that your target services when you run an existing
functional TestCase repeatedly for a desired duration with a desired number of threads (which is
the same as Virtual Users). LoadTests are shown in the Navigator as children to this TestCase;
(here you can see that the Search and Buy TestCase TestCase has four LoadTests defined).
You can create any number of LoadTests for your TestCase either from the TestCase right-click
menu or the TestCase Toolbar with the New LoadTest option. Open the LoadTest window by
double-clicking it in the Navigator (a newly created LoadTest will be opened automatically).
LoadTest Execution
SoapUI allows you to run your LoadTest with as many Threads (=Virtual Users) as your
hardware can manage, depending mainly on memory, CPU, target service response-time, etc. Set
the desired value and start the LoadTest with the Run button at the top left in the LoadTest
window. The underlying TestCase is cloned internally for each configured Thread and started in
its own context; scripts, property-transfers, etc.. will access a unique copy of the TestCase and
its TestSteps which avoids threading-issues at the TestStep and TestCase level (but not higher up
in the hierarchy; if you TestCase modifies TestSuite or Project properties, this will be done on
the common shared ancestor objects). The Thread Startup Delay setting in the LoadTest
Options dialog can be used to introduce a delay between the start of each thread, allowing the
target services (or soapUI) some breathing space for each thread.
Depending on which limit and strategy has been selected, the LoadTest will run as configured
until it terminates due to one of the following:
If the limit is time-based, the Cancel Running option in the LoadTest Options dialog allows
you to control if running threads should be allows to finish or should be canceled. In the same
manor, the Cancel Excessive option controls if excessive threads should be cancelled when
the thread-count decreases (for example when using the Burst Strategy).
Multiple LoadTests can be executed in parallel to test more advanced scenarios, just open several
windows at once and run them side-by-side. A sample scenario for this could be a recovery test
consisting of a simple LoadTest generating baseline traffic and another LoadTest using the Burst
Strategy which creates high traffic in Bursts; after each Burst the baseline LoadTest can assert
that the system handles and recovers as required.