Running mocks and tests using Java and JUnit
Running SoapUI mocks and tests from Java and JUnit is relatively easy to do, as we essentially run the same Java classes that the command line and Maven plugins use. In the first part of this recipe, we will look at running the SoapUIMockServiceRunner
and SoapUITestCaseRunner
files directly. Then, we will look at doing the same via a JUnit runner.
Getting ready
In both cases, we'll run the SOAPMock-soapui-project.xml
project as before. All the code is contained in the chapter 5
samples' /java/
folder.
The samples are easy to run from Eclipse (or a similar IDE) and also from the command line. The minimum you need is a SoapUI and a JDK (this recipe uses JDK 1.7.x).
Unless you're using an IDE, which bundles ...
Get SoapUI Cookbook now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.