List of Input Parameters for VSP
[sdc.git] / openecomp-be / lib / openecomp-sdc-externaltesting-lib / openecomp-sdc-externaltesting-api / src / main / java / org / openecomp / core / externaltesting / api / ExternalTestingManager.java
1 /*
2  * Copyright © 2019 iconectiv
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package org.openecomp.core.externaltesting.api;
18
19
20 import java.util.List;
21
22 public interface ExternalTestingManager {
23
24   /**
25    * Return the configuration of this feature that we want to
26    * expose to the client.  Treated as a JSON blob for flexibility.
27    */
28   String getConfig();
29
30   /**
31    * Build a tree of all test cases for the client including all
32    * defined endpoints, scenarios, and test suites.
33    * @return test case tree.
34    */
35   TestTreeNode getTestCasesAsTree();
36
37   /**
38    * Get a list of testing endpoints with name and description.
39    */
40   List<VtpNameDescriptionPair> getEndpoints();
41
42   /**
43    * Get a list of scenarios from and endpoint.
44    */
45   List<VtpNameDescriptionPair> getScenarios(String endpoint);
46
47   /**
48    * Get a list of test suites given the endpoint and scenario.
49    */
50   List<VtpNameDescriptionPair> getTestSuites(String endpoint, String scenario);
51
52   /**
53    * Get a list of test cases.
54    * @param endpoint endpoint to contact (e.g. VTP)
55    * @param scenario test scenario to get tests for
56    * @return list of test cases.
57    */
58   List<VtpTestCase> getTestCases(String endpoint, String scenario);
59
60   /**
61    * Get the details about a particular test case.
62    * @param endpoint endpoint to contact (e.g. VTP)
63    * @param scenario test scenario to get tests for
64    * @param testSuite suite to get tests for
65    * @param testCaseName test case name to query.
66    * @return details about the test case.
67    */
68   VtpTestCase getTestCase(String endpoint, String scenario, String testSuite, String testCaseName);
69
70   /**
71    * Execute a collection of tests where the manager must distribute
72    * the tests to the appropriate endpoint and correlate the responses.
73    * @param requests collection of request items.
74    * @param requestId optional request ID provided from client.
75    * @return response from endpoint (don't bother to parse).
76    */
77   List<VtpTestExecutionResponse> execute(List<VtpTestExecutionRequest> requests, String requestId);
78
79   /**
80    * Return a previous results.
81    * @param endpoint endpoint to query
82    * @param executionId execution to query.
83    * @return response from endpoint.
84    */
85   VtpTestExecutionResponse getExecution(String endpoint, String executionId);
86
87 }