SoapUI interview questions and answers for API testers
SoapUI interview questions focus on testing web services from a WSDL: building a project, organizing test suites and steps, asserting on XML with namespaces, passing values between steps, and scripting the gaps with Groovy. Panels for banking, insurance, telecom and government integration work ask these most, since SOAP services are common there. Expect a walkthrough of a suite you built, questions on assertions and properties, and a scenario where a service returns a fault or a test passes when it should not.
By Evin JohnPublished 7 min read
How SoapUI shows up in interviews
SoapUI is the open-source API testing tool from SmartBear, with a commercial sibling, ReadyAPI, that adds more data-driven and reporting features. Roles that list it are usually QA or integration test positions around enterprise services, where requests are XML envelopes defined by a WSDL. Interviewers want to see that you can do more than click Send: you should know how to structure a suite, assert on the right element, and keep tests independent of one environment. General HTTP and Postman questions sit on API testing interview questions.
- Service basicsWSDL structure, SOAP versions, faults and how a SOAP call differs from a REST call.
- Tool structureCreating a project from a WSDL, organizing suites, cases and steps, and choosing assertions.
- Data and scriptingProperties, property transfer, Groovy steps and script assertions, often with a short snippet to read.
- ScenariosA false pass, a namespace that broke an assertion, a dependent service that is down, or a suite to run from CI.
SOAP and WSDL fundamentals
| Question | What it tests | What a strong answer shows |
|---|---|---|
| What does a WSDL describe? | Contract | The service's data types (usually XML Schema), the messages, the operations grouped in a port type, the binding to SOAP and a transport, and the endpoint address in the service element. |
| What are the parts of a SOAP message? | Envelope | An Envelope with an optional Header for things like security tokens and a required Body holding the payload or a Fault. |
| SOAP 1.1 versus SOAP 1.2? | Versions | Different envelope namespaces and content types: 1.1 uses text/xml with a separate SOAPAction header, 1.2 uses application/soap+xml with the action as a parameter. Fault elements are named differently too. |
| Document/literal versus RPC/encoded? | Binding style | Document/literal sends a body that validates against the schema and is the interoperable choice. RPC/encoded wraps calls in operation elements with type encoding and is largely legacy. |
| What is a SOAP fault and which HTTP status comes with it? | Errors | A Fault element in the Body with a code and a reason. SOAP over HTTP usually returns 500 for faults, so a test that checks only for a 200 can mislead you in both directions. |
| SOAP versus REST from a tester's point of view? | Comparison | SOAP has a strict contract you can validate against, one endpoint with many operations, and XML only. REST spreads operations over URLs and methods, often uses JSON, and its contract may be an OpenAPI file or nothing at all. |
| How do you create a SoapUI project for a new service? | Setup | Point a new SOAP project at the WSDL URL or file. SoapUI generates an interface with each operation and sample requests filled with placeholders you then complete. |
| What is the difference between a request under an operation and a test step? | Structure | Requests under an interface are for exploring by hand. Test steps live inside test cases with assertions and properties, and they are what you run as a regression suite. |
Test structure and assertions
- How do you organize a suite? One test suite per service or business area, one test case per scenario, and steps inside the case in the order the scenario runs. Each case should set up and clean up its own data so it can run alone.
- Which test step types have you used? SOAP and REST requests, Groovy Script, Property Transfer, Properties, Delay, Conditional Goto, Run TestCase to reuse a flow, and JDBC requests to check what landed in the database.
- Which assertion would you add first to a SOAP response? Not SOAP Fault and Schema Compliance as a safety net, then XPath Match on the specific values the scenario cares about.
- Contains or XPath Match? Contains just searches the response text, so it passes if the value appears anywhere, even in an error message. XPath Match targets one element and compares its value, which is far harder to fool.
- What does Schema Compliance catch that value checks miss? Missing required elements, wrong types and unexpected structure, measured against the WSDL's schema. It will not tell you whether the values are right.
- When do you use a Script Assertion? When the rule needs logic, such as checking that line totals add up to the order total, or that a list is sorted. Keep it short and give it a clear failure message.
- What is the Response SLA assertion for? It fails the step if the response takes longer than a set number of milliseconds. Useful as a smoke check, not a substitute for proper performance testing.
- How do you test that a service fails correctly? Send an invalid request and assert SOAP Fault, then XPath Match on the fault code or message element, so the test fails if the service starts accepting bad input.
import xml.etree.ElementTree as ET
response = """<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:ord="http://example.com/orders">
<soap:Body>
<ord:GetOrderResponse>
<ord:order id="A-1001">
<ord:status>SHIPPED</ord:status>
<ord:line sku="MUG-01" qty="2"/>
<ord:line sku="TEA-07" qty="1"/>
</ord:order>
</ord:GetOrderResponse>
</soap:Body>
</soap:Envelope>"""
ns = {"soap": "http://schemas.xmlsoap.org/soap/envelope/",
"ord": "http://example.com/orders"}
root = ET.fromstring(response)
status = root.find(".//ord:order/ord:status", ns).text
lines = root.findall(".//ord:order/ord:line", ns)
fault = root.find(".//soap:Fault", ns)
print("status:", status, "| lines:", len(lines), "| fault:", fault)
print("no-namespace lookup:", root.find(".//order/status"))
# status: SHIPPED | lines: 2 | fault: None
# no-namespace lookup: NoneThe last line is the point interviewers probe: an XPath written without the namespace finds nothing. In SoapUI the expression starts with namespace declarations, for example declare namespace ord='http://example.com/orders'; followed by //ord:order/ord:status, and the expected value goes in the assertion. A wildcard such as //*:status avoids the declaration but can match the wrong element when two namespaces use the same name.
Properties, transfers and Groovy
| Question | What it tests | What a strong answer shows |
|---|---|---|
| What is property expansion? | Syntax | Placeholders such as ${#Project#baseUrl}, ${#TestCase#orderId} or ${#Env#HOME} that SoapUI replaces before sending. Expansion can also read a value from a previous step's response. |
| Which property scopes exist? | Scope | Global, system, environment, project, test suite, test case and individual Properties steps. The rule of thumb is to keep values at the narrowest scope that works so cases do not leak into each other. |
| What does a Property Transfer step do? | Chaining | Reads a value from one place, usually a response via XPath, and writes it to a property or into the next request. The classic case is taking a session token or new order ID from step one into step two. |
| How do you point the same suite at test and staging? | Environments | Keep endpoints and credentials in project properties and switch them per run, or use the environments feature where your edition has it. Hard-coded endpoints in each request are the anti-pattern. |
| What objects does a Groovy step get? | Scripting API | log for output, context for the run context and property expansion, and testRunner to reach the test case, its properties and other steps. Script assertions get messageExchange with the request and response. |
| How do you run the same case with rows from a CSV? | Data-driven | ReadyAPI offers data source and loop steps. In open-source SoapUI a common pattern is a Groovy step that reads the next row into properties and a Conditional Goto or script that loops back until the rows run out. |
def groovyUtils = new com.eviware.soapui.support.GroovyUtils(context)
def holder = groovyUtils.getXmlHolder("CreateOrder#Response")
holder.namespaces["ord"] = "http://example.com/orders"
def orderId = holder.getNodeValue("//ord:order/@id")
assert orderId : "CreateOrder returned no order id"
testRunner.testCase.setPropertyValue("orderId", orderId)
log.info("Created order " + orderId)Mock services, security and CI: senior questions
| Scenario or question | Topic | What a strong answer covers |
|---|---|---|
| The downstream payment service is not ready yet. How do you test the caller? | Mock services | Generate a mock service from the payment WSDL, add responses for success, decline and fault, and choose a dispatch style (sequence, script, or a match on a request value) so each test gets the right answer. |
| A test passes even though the service returned an error page. | False pass | The only assertion was Contains on a word that also appears in the error, or a status check that treats any response as fine. Add Not SOAP Fault, Schema Compliance and an XPath Match on the business value. |
| After a service release, every XPath assertion fails. | Namespaces | The target namespace changed with the new WSDL version. Update the namespace declarations in one place, or refresh the interface from the new WSDL, and agree on contract versioning with the developers. |
| How do you send a WS-Security UsernameToken? | Security | Configure outgoing WS-Security for the project with a username token, a timestamp and, if required, signing or encryption with a keystore, then apply that configuration to the requests. Never commit real passwords in the project file. |
| How do you run SoapUI tests in a CI pipeline? | Automation | Use the command-line test runner that ships with SoapUI (or a Maven plugin) to run a project, suite or case, pass the endpoint and properties as arguments, and publish its JUnit-style reports. Check the runner's help output for the exact flags in your version. |
| The project file is one huge XML that merges badly. What do you do? | Maintainability | Split into smaller projects per service, keep environment values out of the file, review changes in small commits, and where the edition supports it, use a composite project saved as a folder of files. |
| SoapUI or a code-based framework? | Judgment | SoapUI is fast for WSDL-driven services and for testers who prefer a GUI. A code framework such as REST Assured fits teams that keep tests next to the service code with normal code review. Many teams use both. |
| Can SoapUI load test a service? | Performance | It can run simple load tests with several thread strategies, which suits a quick check. Serious load work usually moves to a dedicated tool such as JMeter or the commercial add-on. |
Fictional example
- Interviewer
- Tell me about a SoapUI suite you are proud of and how it is put together.
- Candidate
- At my last role we tested a policy service with about a dozen SOAP operations. I built one project from the WSDL with endpoints and credentials as project properties, so the same suite ran against test and staging. Each test case followed one business scenario, such as create quote, convert to policy, then cancel. The first step created its own customer, a Property Transfer passed the IDs forward, and a final Groovy step cleaned up. Every response had Not SOAP Fault and Schema Compliance, plus XPath Match on the premium and status. For the rating engine, which was often down in test, I used a mock service with three canned responses. The suite ran nightly from Jenkins through the command-line runner, and the JUnit report went to the team channel.
A SoapUI practice plan
- Pick a public SOAP serviceMany free sample services publish a WSDL. Create a project from it and read the generated requests next to the WSDL's types.
- Write real assertionsFor two operations add Not SOAP Fault, Schema Compliance and an XPath Match with namespaces, then break the expected value to see each fail.
- Chain stepsBuild a two-step case where the second request uses a value from the first through a Property Transfer, then redo it with a Groovy step.
- Mock and faultCreate a mock service with a success and a fault response, and write a negative test that expects the fault.
- Run headlessRun the suite from the command line with a different endpoint, and read the report it writes.
Secured services lead to the developer side in Spring Security interview questions, and checking what a service wrote to its database ties into SQL joins interview questions. For scripting depth, Groovy interview questions covers the language behind SoapUI's scripts.
Suite walkthroughs go better when you can hear how long you spent on setup and how little on assertions. Natively, an AI interview assistant for Mac and Windows, transcribes a practice walkthrough on your own computer, so you can trim it before the real panel. When you rehearse, it can read an XPath, a Groovy step or a fault response from a screenshot and suggest what an interviewer would ask next. It keeps the transcript and your notes, and with Pro or the free trial it tailors suggestions to the résumé and job description you add.
Questions people ask
What SoapUI questions are asked in interviews?
How to build a project from a WSDL, how suites, cases and steps are organized, which assertions to use, how property expansion and Property Transfer work, Groovy scripting, mock services and running tests from the command line.
Why does my SoapUI XPath assertion find nothing?
Usually a missing or wrong namespace. Declare the namespaces the response uses before the expression, or the XPath will not match elements that live in a namespace.
What is the difference between SoapUI and ReadyAPI?
SoapUI is SmartBear's open-source tool. ReadyAPI is the commercial product that adds features such as built-in data sources and richer reporting. Check SmartBear's site for the current feature split.
Can SoapUI test REST APIs too?
Yes. It can create REST projects from a URL or an API definition and use the same suites, assertions and properties, although many teams pick other tools for REST-only work.
Where to go next
Practice with the same assistant you would use on a call: it listens, transcribes and suggests answers from your own resume and the job description.
Facts on this page were last checked on . Product details come from the Natively app itself; if something here is out of date, tell us at hello@heynatively.com.
