action microcks_create_test { label: "Create a new Test" provider: microcks method: POST path: "/tests" encoding: json input: { description: "Test request is a minimalist wrapper for requesting the launch of a new test" required: ["runnerType", "serviceId", "testEndpoint", "timeout"] properties: { filteredOperations: { type: "array" description: "A restriction on service operations to test" items: { type: "string" } } operationHeaders: { type: "object" description: "Specification of additional headers for a Service/API operations. Keys are operation name or \"globals\" (if header applies to all), values are Header objects DTO." } runnerType: { type: "string" description: "Type of test strategy (different strategies are implemented by different runners)" enum: ["HTTP", "SOAP_HTTP", "SOAP_UI", "POSTMAN", "OPEN_API_SCHEMA", "ASYNC_API_SCHEMA", "GRPC_PROTOBUF", "GRAPHQL_SCHEMA"] } secretName: { type: "string" description: "The name of Secret to use for connecting the test endpoint" } serviceId: { type: "string" description: "Unique identifier of service to test" } testEndpoint: { type: "string" description: "Endpoint to test for this service" } timeout: { type: "integer" description: "The maximum time (in milliseconds) to wait for this test ends" } } } output: { description: "Represents the result of a Service or API test run by Microcks. Tests are related to a service and made of multiple test cases corresponding to each operations / actions composing service. Tests are run against a specific endpoint named testedEndpoint. It holds global markers telling if test still ran, is a success, how many times is has taken and so on ..." required: ["id", "inProgress", "runnerType", "serviceId", "success", "testDate", "testNumber", "testedEndpoint", "version"] properties: { elapsedTime: { type: "number" description: "Elapsed time in milliseconds since test beginning" } id: { type: "string" description: "Unique identifier of TestResult" } inProgress: { type: "boolean" description: "Flag telling is test is still in progress" } operationHeaders: { type: "object" description: "Specification of additional headers for a Service/API operations. Keys are operation name or \"globals\" (if header applies to all), values are Header objects DTO." } runnerType: { type: "string" description: "Type of test strategy (different strategies are implemented by different runners)" enum: ["HTTP", "SOAP_HTTP", "SOAP_UI", "POSTMAN", "OPEN_API_SCHEMA", "ASYNC_API_SCHEMA", "GRPC_PROTOBUF", "GRAPHQL_SCHEMA"] } secretRef: { description: "Lightweight reference for an existing Secret" required: ["name", "secretId"] properties: { name: { type: "string" description: "Distinct name of the referenced Secret" } secretId: { type: "string" description: "Unique identifier or referenced Secret" } } } serviceId: { type: "string" description: "Unique identifier of service tested" } success: { type: "boolean" description: "Flag telling if test is a success" } testCaseResults: { type: "array" description: "TestCase results associated to this test" items: { description: "Companion objects for TestResult. Each TestCaseResult correspond to a particuliar service operation / action reference by the operationName field. TestCaseResults owns a collection of TestStepResults (one for every request associated to service operation / action)." required: ["success", "elapsedTime", "operationName"] properties: { elapsedTime: { type: "number" description: "Elapsed time in milliseconds since the test case beginning" } operationName: { type: "string" description: "Name of operation this test case is bound to" } success: { type: "boolean" description: "Flag telling if test case is a success" } testStepResults: { type: "array" description: "Test steps associated to this test case" items: { description: "TestStepResult is an entity embedded within TestCaseResult. They are created for each request associated with an operation / action of a microservice." required: ["success", "elapsedTome"] properties: { elapsedTime: { type: "number" description: "Elapsed time in milliseconds since the test step beginning" } eventMessageName: { type: "string" description: "Name of event this test step is bound to" } message: { type: "string" description: "Error message that may be associated to this test step" } requestName: { type: "string" description: "Name of request this test step is bound to" } success: { type: "boolean" description: "Flag telling if test case is a success" } } } } } } } testDate: { type: "integer" format: "int64" description: "Timestamp of creation date of this service" } testNumber: { type: "number" description: "Incremental number for tracking number of tests of a service" } testedEndpoint: { type: "string" description: "Endpoint used during test" } timeout: { type: "integer" description: "The maximum time (in milliseconds) to wait for this test ends" } version: { type: "number" description: "Revision number of this test" } } } }