Template Test from Specification Document
As an alternative to making requests against an existing API deployment to create a test, instead you can create a test template from a document that specifies the APIs behavior, or use a Postman Collection.
The template will include parameterized requests with payloads if they can be determined and assertions based on the API document.
Once the template has been generated, you may need to make changes to the datasets to use the correct endpoint and complete any request payloads that have been partially generated.
Supported document types
Test Templating supports generating test cases from the following document types
- Swagger 2.0 JSON
- Swagger 2.0 YAML
- SOAP WSDL (single wsdl file)
- Postman Collection
Once the document has been uploaded, you will be presented with a list of requests based on Path and expected status code
Generates a single request and any assertions that can be determined about that request
This replaces an existing test definition
Generate additional request and adds to the end of the existing test case
Note: This does not include any assertions, it is recommended the core request to be tested is generated from scratch and then additional requests merged into it
- OpenAPI 2.0/Swagger 2.0 only
- Enterprise as a Servce and Cloud Pak for Integration only
Once you've enabled the insights-driven test generation feature you will be able to generate a test template which can contain multiple related requests that include setup and teardown operations for the targeted operation.
Smart Generation uses static analysis and natural language processing of the API document to determine links between API requests and data that can to be shared between the requests