testit-js-commons 3.7.9 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/lib/common/types/config.type.d.ts +8 -0
  2. package/lib/common/utils/index.d.ts +1 -0
  3. package/lib/common/utils/index.js +1 -0
  4. package/lib/common/utils/tms-load-test-run-debug.d.ts +3 -0
  5. package/lib/common/utils/tms-load-test-run-debug.js +20 -0
  6. package/lib/helpers/config/config.helper.js +14 -6
  7. package/lib/helpers/config/config.helper.test.d.ts +1 -0
  8. package/lib/helpers/config/config.helper.test.js +40 -0
  9. package/lib/services/attachments/attachments.service.js +89 -22
  10. package/lib/services/index.d.ts +1 -0
  11. package/lib/services/index.js +1 -0
  12. package/lib/services/syncstorage/index.d.ts +2 -0
  13. package/lib/services/syncstorage/index.js +18 -0
  14. package/lib/services/syncstorage/syncstorage.runner.d.ts +49 -0
  15. package/lib/services/syncstorage/syncstorage.runner.js +350 -0
  16. package/lib/services/syncstorage/syncstorage.runner.test.d.ts +1 -0
  17. package/lib/services/syncstorage/syncstorage.runner.test.js +78 -0
  18. package/lib/services/syncstorage/syncstorage.type.d.ts +21 -0
  19. package/lib/services/syncstorage/syncstorage.type.js +19 -0
  20. package/lib/services/testruns/testruns.converter.d.ts +2 -0
  21. package/lib/services/testruns/testruns.converter.js +3 -0
  22. package/lib/services/testruns/testruns.service.d.ts +2 -0
  23. package/lib/services/testruns/testruns.service.js +62 -1
  24. package/lib/services/testruns/testruns.type.d.ts +2 -0
  25. package/lib/strategy/base.strategy.d.ts +4 -0
  26. package/lib/strategy/base.strategy.js +97 -2
  27. package/lib/sync-storage/dist/ApiClient.js +655 -0
  28. package/lib/sync-storage/dist/api/CompletionApi.js +114 -0
  29. package/lib/sync-storage/dist/api/HealthApi.js +69 -0
  30. package/lib/sync-storage/dist/api/SystemApi.js +69 -0
  31. package/lib/sync-storage/dist/api/TestResultsApi.js +122 -0
  32. package/lib/sync-storage/dist/api/WorkersApi.js +113 -0
  33. package/lib/sync-storage/dist/index.js +118 -0
  34. package/lib/sync-storage/dist/model/CompletionResponse.js +86 -0
  35. package/lib/sync-storage/dist/model/HealthStatusResponse.js +86 -0
  36. package/lib/sync-storage/dist/model/InProgressPublishedResponse.js +74 -0
  37. package/lib/sync-storage/dist/model/RegisterRequest.js +114 -0
  38. package/lib/sync-storage/dist/model/RegisterResponse.js +122 -0
  39. package/lib/sync-storage/dist/model/SetWorkerStatusRequest.js +102 -0
  40. package/lib/sync-storage/dist/model/SetWorkerStatusResponse.js +90 -0
  41. package/lib/sync-storage/dist/model/ShutdownResponse.js +90 -0
  42. package/lib/sync-storage/dist/model/TestResultCutApiModel.js +122 -0
  43. package/lib/sync-storage/dist/model/TestResultSaveResponse.js +90 -0
  44. package/lib/sync-storage/index.d.ts +772 -0
  45. package/package.json +7 -4
@@ -0,0 +1,114 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _CompletionResponse = _interopRequireDefault(require("../model/CompletionResponse"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
+ /**
11
+ * Sync Storage Service API
12
+ * This is a sync storage service for coordinating test workers.
13
+ *
14
+ * The version of the OpenAPI document: 1.0
15
+ *
16
+ *
17
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
18
+ * https://openapi-generator.tech
19
+ * Do not edit the class manually.
20
+ *
21
+ */
22
+
23
+ /**
24
+ * Completion service.
25
+ * @module api/CompletionApi
26
+ * @version 0.1.0
27
+ */
28
+ class CompletionApi {
29
+ /**
30
+ * Constructs a new CompletionApi.
31
+ * @alias module:api/CompletionApi
32
+ * @class
33
+ * @param {module:ApiClient} [apiClient] Optional API client implementation to use,
34
+ * default to {@link module:ApiClient#instance} if unspecified.
35
+ */
36
+ constructor(apiClient) {
37
+ this.apiClient = apiClient || _ApiClient.default.instance;
38
+ }
39
+
40
+ /**
41
+ * Force completion of a test run
42
+ * Force processing completion for a specific test run.
43
+ * @param {String} testRunId Test Run ID
44
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/CompletionResponse} and HTTP response
45
+ */
46
+ forceCompletionGetWithHttpInfo(testRunId) {
47
+ let postBody = null;
48
+ // verify the required parameter 'testRunId' is set
49
+ if (testRunId === undefined || testRunId === null) {
50
+ throw new Error("Missing the required parameter 'testRunId' when calling forceCompletionGet");
51
+ }
52
+ let pathParams = {};
53
+ let queryParams = {
54
+ 'testRunId': testRunId
55
+ };
56
+ let headerParams = {};
57
+ let formParams = {};
58
+ let authNames = [];
59
+ let contentTypes = [];
60
+ let accepts = ['application/json'];
61
+ let returnType = _CompletionResponse.default;
62
+ return this.apiClient.callApi('/force-completion', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
63
+ }
64
+
65
+ /**
66
+ * Force completion of a test run
67
+ * Force processing completion for a specific test run.
68
+ * @param {String} testRunId Test Run ID
69
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/CompletionResponse}
70
+ */
71
+ forceCompletionGet(testRunId) {
72
+ return this.forceCompletionGetWithHttpInfo(testRunId).then(function (response_and_data) {
73
+ return response_and_data.data;
74
+ });
75
+ }
76
+
77
+ /**
78
+ * Wait for completion
79
+ * Wait until processing is completed for a test run.
80
+ * @param {String} testRunId Test Run ID
81
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/CompletionResponse} and HTTP response
82
+ */
83
+ waitCompletionGetWithHttpInfo(testRunId) {
84
+ let postBody = null;
85
+ // verify the required parameter 'testRunId' is set
86
+ if (testRunId === undefined || testRunId === null) {
87
+ throw new Error("Missing the required parameter 'testRunId' when calling waitCompletionGet");
88
+ }
89
+ let pathParams = {};
90
+ let queryParams = {
91
+ 'testRunId': testRunId
92
+ };
93
+ let headerParams = {};
94
+ let formParams = {};
95
+ let authNames = [];
96
+ let contentTypes = [];
97
+ let accepts = ['application/json'];
98
+ let returnType = _CompletionResponse.default;
99
+ return this.apiClient.callApi('/wait-completion', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
100
+ }
101
+
102
+ /**
103
+ * Wait for completion
104
+ * Wait until processing is completed for a test run.
105
+ * @param {String} testRunId Test Run ID
106
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/CompletionResponse}
107
+ */
108
+ waitCompletionGet(testRunId) {
109
+ return this.waitCompletionGetWithHttpInfo(testRunId).then(function (response_and_data) {
110
+ return response_and_data.data;
111
+ });
112
+ }
113
+ }
114
+ exports.default = CompletionApi;
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _HealthStatusResponse = _interopRequireDefault(require("../model/HealthStatusResponse"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
+ /**
11
+ * Sync Storage Service API
12
+ * This is a sync storage service for coordinating test workers.
13
+ *
14
+ * The version of the OpenAPI document: 1.0
15
+ *
16
+ *
17
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
18
+ * https://openapi-generator.tech
19
+ * Do not edit the class manually.
20
+ *
21
+ */
22
+
23
+ /**
24
+ * Health service.
25
+ * @module api/HealthApi
26
+ * @version 0.1.0
27
+ */
28
+ class HealthApi {
29
+ /**
30
+ * Constructs a new HealthApi.
31
+ * @alias module:api/HealthApi
32
+ * @class
33
+ * @param {module:ApiClient} [apiClient] Optional API client implementation to use,
34
+ * default to {@link module:ApiClient#instance} if unspecified.
35
+ */
36
+ constructor(apiClient) {
37
+ this.apiClient = apiClient || _ApiClient.default.instance;
38
+ }
39
+
40
+ /**
41
+ * Health check
42
+ * Get the current health status of the service.
43
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/HealthStatusResponse} and HTTP response
44
+ */
45
+ healthGetWithHttpInfo() {
46
+ let postBody = null;
47
+ let pathParams = {};
48
+ let queryParams = {};
49
+ let headerParams = {};
50
+ let formParams = {};
51
+ let authNames = [];
52
+ let contentTypes = [];
53
+ let accepts = ['application/json'];
54
+ let returnType = _HealthStatusResponse.default;
55
+ return this.apiClient.callApi('/health', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
56
+ }
57
+
58
+ /**
59
+ * Health check
60
+ * Get the current health status of the service.
61
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/HealthStatusResponse}
62
+ */
63
+ healthGet() {
64
+ return this.healthGetWithHttpInfo().then(function (response_and_data) {
65
+ return response_and_data.data;
66
+ });
67
+ }
68
+ }
69
+ exports.default = HealthApi;
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _ShutdownResponse = _interopRequireDefault(require("../model/ShutdownResponse"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
+ /**
11
+ * Sync Storage Service API
12
+ * This is a sync storage service for coordinating test workers.
13
+ *
14
+ * The version of the OpenAPI document: 1.0
15
+ *
16
+ *
17
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
18
+ * https://openapi-generator.tech
19
+ * Do not edit the class manually.
20
+ *
21
+ */
22
+
23
+ /**
24
+ * System service.
25
+ * @module api/SystemApi
26
+ * @version 0.1.0
27
+ */
28
+ class SystemApi {
29
+ /**
30
+ * Constructs a new SystemApi.
31
+ * @alias module:api/SystemApi
32
+ * @class
33
+ * @param {module:ApiClient} [apiClient] Optional API client implementation to use,
34
+ * default to {@link module:ApiClient#instance} if unspecified.
35
+ */
36
+ constructor(apiClient) {
37
+ this.apiClient = apiClient || _ApiClient.default.instance;
38
+ }
39
+
40
+ /**
41
+ * Shutdown service
42
+ * Initiate shutdown of the service.
43
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/ShutdownResponse} and HTTP response
44
+ */
45
+ shutdownPostWithHttpInfo() {
46
+ let postBody = null;
47
+ let pathParams = {};
48
+ let queryParams = {};
49
+ let headerParams = {};
50
+ let formParams = {};
51
+ let authNames = [];
52
+ let contentTypes = [];
53
+ let accepts = ['application/json'];
54
+ let returnType = _ShutdownResponse.default;
55
+ return this.apiClient.callApi('/shutdown', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
56
+ }
57
+
58
+ /**
59
+ * Shutdown service
60
+ * Initiate shutdown of the service.
61
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/ShutdownResponse}
62
+ */
63
+ shutdownPost() {
64
+ return this.shutdownPostWithHttpInfo().then(function (response_and_data) {
65
+ return response_and_data.data;
66
+ });
67
+ }
68
+ }
69
+ exports.default = SystemApi;
@@ -0,0 +1,122 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _InProgressPublishedResponse = _interopRequireDefault(require("../model/InProgressPublishedResponse"));
9
+ var _TestResultCutApiModel = _interopRequireDefault(require("../model/TestResultCutApiModel"));
10
+ var _TestResultSaveResponse = _interopRequireDefault(require("../model/TestResultSaveResponse"));
11
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
+ /**
13
+ * Sync Storage Service API
14
+ * This is a sync storage service for coordinating test workers.
15
+ *
16
+ * The version of the OpenAPI document: 1.0
17
+ *
18
+ *
19
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
20
+ * https://openapi-generator.tech
21
+ * Do not edit the class manually.
22
+ *
23
+ */
24
+
25
+ /**
26
+ * TestResults service.
27
+ * @module api/TestResultsApi
28
+ * @version 0.1.0
29
+ */
30
+ class TestResultsApi {
31
+ /**
32
+ * Constructs a new TestResultsApi.
33
+ * @alias module:api/TestResultsApi
34
+ * @class
35
+ * @param {module:ApiClient} [apiClient] Optional API client implementation to use,
36
+ * default to {@link module:ApiClient#instance} if unspecified.
37
+ */
38
+ constructor(apiClient) {
39
+ this.apiClient = apiClient || _ApiClient.default.instance;
40
+ }
41
+
42
+ /**
43
+ * Get in-progress published state
44
+ * Get whether in-progress status has already been published by master node.
45
+ * @param {String} testRunId Test Run ID
46
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/InProgressPublishedResponse} and HTTP response
47
+ */
48
+ inProgressPublishedGetWithHttpInfo(testRunId) {
49
+ let postBody = null;
50
+ // verify the required parameter 'testRunId' is set
51
+ if (testRunId === undefined || testRunId === null) {
52
+ throw new Error("Missing the required parameter 'testRunId' when calling inProgressPublishedGet");
53
+ }
54
+ let pathParams = {};
55
+ let queryParams = {
56
+ 'testRunId': testRunId
57
+ };
58
+ let headerParams = {};
59
+ let formParams = {};
60
+ let authNames = [];
61
+ let contentTypes = [];
62
+ let accepts = ['application/json'];
63
+ let returnType = _InProgressPublishedResponse.default;
64
+ return this.apiClient.callApi('/in_progress_published', 'GET', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
65
+ }
66
+
67
+ /**
68
+ * Get in-progress published state
69
+ * Get whether in-progress status has already been published by master node.
70
+ * @param {String} testRunId Test Run ID
71
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/InProgressPublishedResponse}
72
+ */
73
+ inProgressPublishedGet(testRunId) {
74
+ return this.inProgressPublishedGetWithHttpInfo(testRunId).then(function (response_and_data) {
75
+ return response_and_data.data;
76
+ });
77
+ }
78
+
79
+ /**
80
+ * Save in-progress test result
81
+ * Save a test result with InProgress status.
82
+ * @param {String} testRunId Test Run ID
83
+ * @param {module:model/TestResultCutApiModel} testResultCutApiModel
84
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/TestResultSaveResponse} and HTTP response
85
+ */
86
+ inProgressTestResultPostWithHttpInfo(testRunId, testResultCutApiModel) {
87
+ let postBody = testResultCutApiModel;
88
+ // verify the required parameter 'testRunId' is set
89
+ if (testRunId === undefined || testRunId === null) {
90
+ throw new Error("Missing the required parameter 'testRunId' when calling inProgressTestResultPost");
91
+ }
92
+ // verify the required parameter 'testResultCutApiModel' is set
93
+ if (testResultCutApiModel === undefined || testResultCutApiModel === null) {
94
+ throw new Error("Missing the required parameter 'testResultCutApiModel' when calling inProgressTestResultPost");
95
+ }
96
+ let pathParams = {};
97
+ let queryParams = {
98
+ 'testRunId': testRunId
99
+ };
100
+ let headerParams = {};
101
+ let formParams = {};
102
+ let authNames = [];
103
+ let contentTypes = ['application/json'];
104
+ let accepts = ['application/json'];
105
+ let returnType = _TestResultSaveResponse.default;
106
+ return this.apiClient.callApi('/in_progress_test_result', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
107
+ }
108
+
109
+ /**
110
+ * Save in-progress test result
111
+ * Save a test result with InProgress status.
112
+ * @param {String} testRunId Test Run ID
113
+ * @param {module:model/TestResultCutApiModel} testResultCutApiModel
114
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/TestResultSaveResponse}
115
+ */
116
+ inProgressTestResultPost(testRunId, testResultCutApiModel) {
117
+ return this.inProgressTestResultPostWithHttpInfo(testRunId, testResultCutApiModel).then(function (response_and_data) {
118
+ return response_and_data.data;
119
+ });
120
+ }
121
+ }
122
+ exports.default = TestResultsApi;
@@ -0,0 +1,113 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _RegisterRequest = _interopRequireDefault(require("../model/RegisterRequest"));
9
+ var _RegisterResponse = _interopRequireDefault(require("../model/RegisterResponse"));
10
+ var _SetWorkerStatusRequest = _interopRequireDefault(require("../model/SetWorkerStatusRequest"));
11
+ var _SetWorkerStatusResponse = _interopRequireDefault(require("../model/SetWorkerStatusResponse"));
12
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
13
+ /**
14
+ * Sync Storage Service API
15
+ * This is a sync storage service for coordinating test workers.
16
+ *
17
+ * The version of the OpenAPI document: 1.0
18
+ *
19
+ *
20
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
21
+ * https://openapi-generator.tech
22
+ * Do not edit the class manually.
23
+ *
24
+ */
25
+
26
+ /**
27
+ * Workers service.
28
+ * @module api/WorkersApi
29
+ * @version 0.1.0
30
+ */
31
+ class WorkersApi {
32
+ /**
33
+ * Constructs a new WorkersApi.
34
+ * @alias module:api/WorkersApi
35
+ * @class
36
+ * @param {module:ApiClient} [apiClient] Optional API client implementation to use,
37
+ * default to {@link module:ApiClient#instance} if unspecified.
38
+ */
39
+ constructor(apiClient) {
40
+ this.apiClient = apiClient || _ApiClient.default.instance;
41
+ }
42
+
43
+ /**
44
+ * Register a new worker
45
+ * Register a new worker with the sync storage service.
46
+ * @param {module:model/RegisterRequest} registerRequest
47
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/RegisterResponse} and HTTP response
48
+ */
49
+ registerPostWithHttpInfo(registerRequest) {
50
+ let postBody = registerRequest;
51
+ // verify the required parameter 'registerRequest' is set
52
+ if (registerRequest === undefined || registerRequest === null) {
53
+ throw new Error("Missing the required parameter 'registerRequest' when calling registerPost");
54
+ }
55
+ let pathParams = {};
56
+ let queryParams = {};
57
+ let headerParams = {};
58
+ let formParams = {};
59
+ let authNames = [];
60
+ let contentTypes = ['application/json'];
61
+ let accepts = ['application/json'];
62
+ let returnType = _RegisterResponse.default;
63
+ return this.apiClient.callApi('/register', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
64
+ }
65
+
66
+ /**
67
+ * Register a new worker
68
+ * Register a new worker with the sync storage service.
69
+ * @param {module:model/RegisterRequest} registerRequest
70
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/RegisterResponse}
71
+ */
72
+ registerPost(registerRequest) {
73
+ return this.registerPostWithHttpInfo(registerRequest).then(function (response_and_data) {
74
+ return response_and_data.data;
75
+ });
76
+ }
77
+
78
+ /**
79
+ * Set worker status
80
+ * Set the status of a worker by its PID.
81
+ * @param {module:model/SetWorkerStatusRequest} setWorkerStatusRequest
82
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with an object containing data of type {@link module:model/SetWorkerStatusResponse} and HTTP response
83
+ */
84
+ setWorkerStatusPostWithHttpInfo(setWorkerStatusRequest) {
85
+ let postBody = setWorkerStatusRequest;
86
+ // verify the required parameter 'setWorkerStatusRequest' is set
87
+ if (setWorkerStatusRequest === undefined || setWorkerStatusRequest === null) {
88
+ throw new Error("Missing the required parameter 'setWorkerStatusRequest' when calling setWorkerStatusPost");
89
+ }
90
+ let pathParams = {};
91
+ let queryParams = {};
92
+ let headerParams = {};
93
+ let formParams = {};
94
+ let authNames = [];
95
+ let contentTypes = ['application/json'];
96
+ let accepts = ['application/json', 'text/plain'];
97
+ let returnType = _SetWorkerStatusResponse.default;
98
+ return this.apiClient.callApi('/set_worker_status', 'POST', pathParams, queryParams, headerParams, formParams, postBody, authNames, contentTypes, accepts, returnType, null);
99
+ }
100
+
101
+ /**
102
+ * Set worker status
103
+ * Set the status of a worker by its PID.
104
+ * @param {module:model/SetWorkerStatusRequest} setWorkerStatusRequest
105
+ * @return {Promise} a {@link https://www.promisejs.org/|Promise}, with data of type {@link module:model/SetWorkerStatusResponse}
106
+ */
107
+ setWorkerStatusPost(setWorkerStatusRequest) {
108
+ return this.setWorkerStatusPostWithHttpInfo(setWorkerStatusRequest).then(function (response_and_data) {
109
+ return response_and_data.data;
110
+ });
111
+ }
112
+ }
113
+ exports.default = WorkersApi;
@@ -0,0 +1,118 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "ApiClient", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _ApiClient.default;
10
+ }
11
+ });
12
+ Object.defineProperty(exports, "CompletionApi", {
13
+ enumerable: true,
14
+ get: function () {
15
+ return _CompletionApi.default;
16
+ }
17
+ });
18
+ Object.defineProperty(exports, "CompletionResponse", {
19
+ enumerable: true,
20
+ get: function () {
21
+ return _CompletionResponse.default;
22
+ }
23
+ });
24
+ Object.defineProperty(exports, "HealthApi", {
25
+ enumerable: true,
26
+ get: function () {
27
+ return _HealthApi.default;
28
+ }
29
+ });
30
+ Object.defineProperty(exports, "HealthStatusResponse", {
31
+ enumerable: true,
32
+ get: function () {
33
+ return _HealthStatusResponse.default;
34
+ }
35
+ });
36
+ Object.defineProperty(exports, "InProgressPublishedResponse", {
37
+ enumerable: true,
38
+ get: function () {
39
+ return _InProgressPublishedResponse.default;
40
+ }
41
+ });
42
+ Object.defineProperty(exports, "RegisterRequest", {
43
+ enumerable: true,
44
+ get: function () {
45
+ return _RegisterRequest.default;
46
+ }
47
+ });
48
+ Object.defineProperty(exports, "RegisterResponse", {
49
+ enumerable: true,
50
+ get: function () {
51
+ return _RegisterResponse.default;
52
+ }
53
+ });
54
+ Object.defineProperty(exports, "SetWorkerStatusRequest", {
55
+ enumerable: true,
56
+ get: function () {
57
+ return _SetWorkerStatusRequest.default;
58
+ }
59
+ });
60
+ Object.defineProperty(exports, "SetWorkerStatusResponse", {
61
+ enumerable: true,
62
+ get: function () {
63
+ return _SetWorkerStatusResponse.default;
64
+ }
65
+ });
66
+ Object.defineProperty(exports, "ShutdownResponse", {
67
+ enumerable: true,
68
+ get: function () {
69
+ return _ShutdownResponse.default;
70
+ }
71
+ });
72
+ Object.defineProperty(exports, "SystemApi", {
73
+ enumerable: true,
74
+ get: function () {
75
+ return _SystemApi.default;
76
+ }
77
+ });
78
+ Object.defineProperty(exports, "TestResultCutApiModel", {
79
+ enumerable: true,
80
+ get: function () {
81
+ return _TestResultCutApiModel.default;
82
+ }
83
+ });
84
+ Object.defineProperty(exports, "TestResultSaveResponse", {
85
+ enumerable: true,
86
+ get: function () {
87
+ return _TestResultSaveResponse.default;
88
+ }
89
+ });
90
+ Object.defineProperty(exports, "TestResultsApi", {
91
+ enumerable: true,
92
+ get: function () {
93
+ return _TestResultsApi.default;
94
+ }
95
+ });
96
+ Object.defineProperty(exports, "WorkersApi", {
97
+ enumerable: true,
98
+ get: function () {
99
+ return _WorkersApi.default;
100
+ }
101
+ });
102
+ var _ApiClient = _interopRequireDefault(require("./ApiClient"));
103
+ var _CompletionResponse = _interopRequireDefault(require("./model/CompletionResponse"));
104
+ var _HealthStatusResponse = _interopRequireDefault(require("./model/HealthStatusResponse"));
105
+ var _InProgressPublishedResponse = _interopRequireDefault(require("./model/InProgressPublishedResponse"));
106
+ var _RegisterRequest = _interopRequireDefault(require("./model/RegisterRequest"));
107
+ var _RegisterResponse = _interopRequireDefault(require("./model/RegisterResponse"));
108
+ var _SetWorkerStatusRequest = _interopRequireDefault(require("./model/SetWorkerStatusRequest"));
109
+ var _SetWorkerStatusResponse = _interopRequireDefault(require("./model/SetWorkerStatusResponse"));
110
+ var _ShutdownResponse = _interopRequireDefault(require("./model/ShutdownResponse"));
111
+ var _TestResultCutApiModel = _interopRequireDefault(require("./model/TestResultCutApiModel"));
112
+ var _TestResultSaveResponse = _interopRequireDefault(require("./model/TestResultSaveResponse"));
113
+ var _CompletionApi = _interopRequireDefault(require("./api/CompletionApi"));
114
+ var _HealthApi = _interopRequireDefault(require("./api/HealthApi"));
115
+ var _SystemApi = _interopRequireDefault(require("./api/SystemApi"));
116
+ var _TestResultsApi = _interopRequireDefault(require("./api/TestResultsApi"));
117
+ var _WorkersApi = _interopRequireDefault(require("./api/WorkersApi"));
118
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
@@ -0,0 +1,86 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
9
+ /**
10
+ * Sync Storage Service API
11
+ * This is a sync storage service for coordinating test workers.
12
+ *
13
+ * The version of the OpenAPI document: 1.0
14
+ *
15
+ *
16
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
17
+ * https://openapi-generator.tech
18
+ * Do not edit the class manually.
19
+ *
20
+ */
21
+
22
+ /**
23
+ * The CompletionResponse model module.
24
+ * @module model/CompletionResponse
25
+ * @version 0.1.0
26
+ */
27
+ class CompletionResponse {
28
+ /**
29
+ * Constructs a new <code>CompletionResponse</code>.
30
+ * @alias module:model/CompletionResponse
31
+ */
32
+ constructor() {
33
+ CompletionResponse.initialize(this);
34
+ }
35
+
36
+ /**
37
+ * Initializes the fields of this object.
38
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
39
+ * Only for internal use.
40
+ */
41
+ static initialize(obj) {}
42
+
43
+ /**
44
+ * Constructs a <code>CompletionResponse</code> from a plain JavaScript object, optionally creating a new instance.
45
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
46
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
47
+ * @param {module:model/CompletionResponse} obj Optional instance to populate.
48
+ * @return {module:model/CompletionResponse} The populated <code>CompletionResponse</code> instance.
49
+ */
50
+ static constructFromObject(data, obj) {
51
+ if (data) {
52
+ obj = obj || new CompletionResponse();
53
+ if (data.hasOwnProperty('completed')) {
54
+ obj['completed'] = _ApiClient.default.convertToType(data['completed'], 'Boolean');
55
+ }
56
+ if (data.hasOwnProperty('message')) {
57
+ obj['message'] = _ApiClient.default.convertToType(data['message'], 'String');
58
+ }
59
+ }
60
+ return obj;
61
+ }
62
+
63
+ /**
64
+ * Validates the JSON data with respect to <code>CompletionResponse</code>.
65
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
66
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>CompletionResponse</code>.
67
+ */
68
+ static validateJSON(data) {
69
+ // ensure the json data is a string
70
+ if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
71
+ throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
72
+ }
73
+ return true;
74
+ }
75
+ }
76
+
77
+ /**
78
+ * @member {Boolean} completed
79
+ */
80
+ CompletionResponse.prototype['completed'] = undefined;
81
+
82
+ /**
83
+ * @member {String} message
84
+ */
85
+ CompletionResponse.prototype['message'] = undefined;
86
+ var _default = exports.default = CompletionResponse;