testit-js-commons 4.2.0-TMS-5.8 → 5.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 (157) hide show
  1. package/lib/adapters-api/dist/ApiClient.js +683 -0
  2. package/lib/adapters-api/dist/api/AttachmentsApi.js +165 -0
  3. package/lib/adapters-api/dist/api/AutoTestsApi.js +536 -0
  4. package/lib/adapters-api/dist/api/ConfigurationsApi.js +91 -0
  5. package/lib/adapters-api/dist/api/ParametersApi.js +159 -0
  6. package/lib/adapters-api/dist/api/ProjectAttributesApi.js +140 -0
  7. package/lib/adapters-api/dist/api/ProjectSectionsApi.js +96 -0
  8. package/lib/adapters-api/dist/api/ProjectWorkItemsApi.js +99 -0
  9. package/lib/adapters-api/dist/api/ProjectsApi.js +200 -0
  10. package/lib/adapters-api/dist/api/SectionsApi.js +118 -0
  11. package/lib/adapters-api/dist/api/TestResultsApi.js +168 -0
  12. package/lib/adapters-api/dist/api/TestRunsApi.js +331 -0
  13. package/lib/adapters-api/dist/api/WorkItemsApi.js +170 -0
  14. package/lib/adapters-api/dist/api/WorkflowsApi.js +75 -0
  15. package/lib/adapters-api/dist/index.js +951 -0
  16. package/lib/adapters-api/dist/model/AssignAttachmentApiModel.js +89 -0
  17. package/lib/adapters-api/dist/model/AssignAutoTestCaseIdApiModel.js +89 -0
  18. package/lib/adapters-api/dist/model/AssignIterationApiModel.js +112 -0
  19. package/lib/adapters-api/dist/model/AttachmentApiResult.js +145 -0
  20. package/lib/adapters-api/dist/model/AttachmentModel.js +193 -0
  21. package/lib/adapters-api/dist/model/AttachmentPutModel.js +89 -0
  22. package/lib/adapters-api/dist/model/AttachmentPutModelAutoTestStepResultsModel.js +196 -0
  23. package/lib/adapters-api/dist/model/AttachmentUpdateRequest.js +89 -0
  24. package/lib/adapters-api/dist/model/AutoTest.js +327 -0
  25. package/lib/adapters-api/dist/model/AutoTestApiResult.js +323 -0
  26. package/lib/adapters-api/dist/model/AutoTestCaseApiModel.js +89 -0
  27. package/lib/adapters-api/dist/model/AutoTestCreateApiModel.js +323 -0
  28. package/lib/adapters-api/dist/model/AutoTestFilterApiModel.js +201 -0
  29. package/lib/adapters-api/dist/model/AutoTestIdModel.js +88 -0
  30. package/lib/adapters-api/dist/model/AutoTestModel.js +488 -0
  31. package/lib/adapters-api/dist/model/AutoTestResultReasonShort.js +99 -0
  32. package/lib/adapters-api/dist/model/AutoTestResultsForTestRunModel.js +334 -0
  33. package/lib/adapters-api/dist/model/AutoTestSearchApiModel.js +96 -0
  34. package/lib/adapters-api/dist/model/AutoTestSearchIncludeApiModel.js +93 -0
  35. package/lib/adapters-api/dist/model/AutoTestStep.js +123 -0
  36. package/lib/adapters-api/dist/model/AutoTestStepApiModel.js +123 -0
  37. package/lib/adapters-api/dist/model/AutoTestStepApiResult.js +123 -0
  38. package/lib/adapters-api/dist/model/AutoTestStepModel.js +123 -0
  39. package/lib/adapters-api/dist/model/AutoTestStepResult.js +196 -0
  40. package/lib/adapters-api/dist/model/AutoTestStepResultUpdateRequest.js +196 -0
  41. package/lib/adapters-api/dist/model/AutoTestUpdateApiModel.js +327 -0
  42. package/lib/adapters-api/dist/model/AutoTestWorkItemIdentifierApiResult.js +100 -0
  43. package/lib/adapters-api/dist/model/AvailableTestResultOutcome.js +67 -0
  44. package/lib/adapters-api/dist/model/ConfigurationFilterModel.js +114 -0
  45. package/lib/adapters-api/dist/model/ConfigurationModel.js +213 -0
  46. package/lib/adapters-api/dist/model/ConfigurationShortModel.js +102 -0
  47. package/lib/adapters-api/dist/model/CreateEmptyTestRunApiModel.js +185 -0
  48. package/lib/adapters-api/dist/model/CreateLinkApiModel.js +127 -0
  49. package/lib/adapters-api/dist/model/CreateParameterApiModel.js +117 -0
  50. package/lib/adapters-api/dist/model/CreateProjectApiModel.js +124 -0
  51. package/lib/adapters-api/dist/model/CreateStepApiModel.js +131 -0
  52. package/lib/adapters-api/dist/model/CreateWorkItemApiModel.js +384 -0
  53. package/lib/adapters-api/dist/model/CustomAttributeApiResult.js +184 -0
  54. package/lib/adapters-api/dist/model/CustomAttributeGetModel.js +184 -0
  55. package/lib/adapters-api/dist/model/CustomAttributeOptionApiResult.js +124 -0
  56. package/lib/adapters-api/dist/model/CustomAttributeOptionModel.js +124 -0
  57. package/lib/adapters-api/dist/model/CustomAttributePutModel.js +182 -0
  58. package/lib/adapters-api/dist/model/CustomAttributeType.js +73 -0
  59. package/lib/adapters-api/dist/model/CustomAttributeTypesEnum.js +73 -0
  60. package/lib/adapters-api/dist/model/DateTimeRangeSelectorModel.js +82 -0
  61. package/lib/adapters-api/dist/model/DeletionState.js +55 -0
  62. package/lib/adapters-api/dist/model/DetailedProjectApiResult.js +204 -0
  63. package/lib/adapters-api/dist/model/FailureCategoryModel.js +67 -0
  64. package/lib/adapters-api/dist/model/GuidExtractionModel.js +90 -0
  65. package/lib/adapters-api/dist/model/ImageResizeType.js +49 -0
  66. package/lib/adapters-api/dist/model/Int32RangeSelectorModel.js +82 -0
  67. package/lib/adapters-api/dist/model/Int64RangeSelectorModel.js +82 -0
  68. package/lib/adapters-api/dist/model/IterationApiResult.js +109 -0
  69. package/lib/adapters-api/dist/model/IterationModel.js +109 -0
  70. package/lib/adapters-api/dist/model/LabelApiModel.js +100 -0
  71. package/lib/adapters-api/dist/model/LabelApiResult.js +100 -0
  72. package/lib/adapters-api/dist/model/LabelShortModel.js +100 -0
  73. package/lib/adapters-api/dist/model/LinkApiResult.js +140 -0
  74. package/lib/adapters-api/dist/model/LinkCreateApiModel.js +127 -0
  75. package/lib/adapters-api/dist/model/LinkModel.js +149 -0
  76. package/lib/adapters-api/dist/model/LinkPostModel.js +137 -0
  77. package/lib/adapters-api/dist/model/LinkPutModel.js +149 -0
  78. package/lib/adapters-api/dist/model/LinkShortApiResult.js +126 -0
  79. package/lib/adapters-api/dist/model/LinkType.js +73 -0
  80. package/lib/adapters-api/dist/model/LinkUpdateApiModel.js +140 -0
  81. package/lib/adapters-api/dist/model/ManualRerunApiResult.js +84 -0
  82. package/lib/adapters-api/dist/model/ManualRerunSelectTestResultsApiModel.js +109 -0
  83. package/lib/adapters-api/dist/model/ManualRerunTestResultApiModel.js +81 -0
  84. package/lib/adapters-api/dist/model/Operation.js +110 -0
  85. package/lib/adapters-api/dist/model/ParameterApiResult.js +154 -0
  86. package/lib/adapters-api/dist/model/ParameterIterationModel.js +100 -0
  87. package/lib/adapters-api/dist/model/ParameterShortApiResult.js +132 -0
  88. package/lib/adapters-api/dist/model/ParameterShortModel.js +158 -0
  89. package/lib/adapters-api/dist/model/ParametersFilterApiModel.js +98 -0
  90. package/lib/adapters-api/dist/model/ProblemDetails.js +124 -0
  91. package/lib/adapters-api/dist/model/ProjectApiResult.js +165 -0
  92. package/lib/adapters-api/dist/model/ProjectAttributesFilterModel.js +132 -0
  93. package/lib/adapters-api/dist/model/ProjectTypeModel.js +49 -0
  94. package/lib/adapters-api/dist/model/ProjectsFilterModel.js +209 -0
  95. package/lib/adapters-api/dist/model/SectionModel.js +180 -0
  96. package/lib/adapters-api/dist/model/SectionPostModel.js +178 -0
  97. package/lib/adapters-api/dist/model/SectionWithStepsModel.js +242 -0
  98. package/lib/adapters-api/dist/model/SharedStepModel.js +145 -0
  99. package/lib/adapters-api/dist/model/SharedStepResultApiModel.js +102 -0
  100. package/lib/adapters-api/dist/model/StepCommentApiModel.js +207 -0
  101. package/lib/adapters-api/dist/model/StepModel.js +163 -0
  102. package/lib/adapters-api/dist/model/StepPostModel.js +126 -0
  103. package/lib/adapters-api/dist/model/StepResultApiModel.js +149 -0
  104. package/lib/adapters-api/dist/model/TagModel.js +88 -0
  105. package/lib/adapters-api/dist/model/TestResultLinkApiResult.js +153 -0
  106. package/lib/adapters-api/dist/model/TestResultOutcome.js +67 -0
  107. package/lib/adapters-api/dist/model/TestResultResponse.js +400 -0
  108. package/lib/adapters-api/dist/model/TestResultShortResponse.js +311 -0
  109. package/lib/adapters-api/dist/model/TestResultStepCommentUpdateRequest.js +152 -0
  110. package/lib/adapters-api/dist/model/TestResultUpdateRequest.js +285 -0
  111. package/lib/adapters-api/dist/model/TestResultsFilterApiModel.js +226 -0
  112. package/lib/adapters-api/dist/model/TestRunApiResult.js +196 -0
  113. package/lib/adapters-api/dist/model/TestRunState.js +61 -0
  114. package/lib/adapters-api/dist/model/TestStatusApiResult.js +114 -0
  115. package/lib/adapters-api/dist/model/TestStatusApiType.js +67 -0
  116. package/lib/adapters-api/dist/model/TestStatusModel.js +149 -0
  117. package/lib/adapters-api/dist/model/TestStatusType.js +67 -0
  118. package/lib/adapters-api/dist/model/UpdateEmptyTestRunApiModel.js +187 -0
  119. package/lib/adapters-api/dist/model/UpdateLinkApiModel.js +140 -0
  120. package/lib/adapters-api/dist/model/ValidationProblemDetails.js +144 -0
  121. package/lib/adapters-api/dist/model/WorkItemApiResult.js +499 -0
  122. package/lib/adapters-api/dist/model/WorkItemEntityTypeApiModel.js +55 -0
  123. package/lib/adapters-api/dist/model/WorkItemFilterApiModel.js +309 -0
  124. package/lib/adapters-api/dist/model/WorkItemIdApiModel.js +89 -0
  125. package/lib/adapters-api/dist/model/WorkItemParameterKeyApiModel.js +89 -0
  126. package/lib/adapters-api/dist/model/WorkItemParameterKeyApiResult.js +88 -0
  127. package/lib/adapters-api/dist/model/WorkItemPriorityApiModel.js +67 -0
  128. package/lib/adapters-api/dist/model/WorkItemPriorityModel.js +67 -0
  129. package/lib/adapters-api/dist/model/WorkItemSelectApiModel.js +90 -0
  130. package/lib/adapters-api/dist/model/WorkItemShortApiResult.js +316 -0
  131. package/lib/adapters-api/dist/model/WorkItemSourceTypeModel.js +49 -0
  132. package/lib/adapters-api/dist/model/WorkItemStateApiModel.js +55 -0
  133. package/lib/adapters-api/dist/model/WorkItemStates.js +55 -0
  134. package/lib/adapters-api/dist/model/WorkItemTypeModel.js +55 -0
  135. package/lib/adapters-api/dist/model/WorkflowApiResult.js +111 -0
  136. package/lib/adapters-api/dist/model/WorkflowStatusApiResult.js +114 -0
  137. package/lib/adapters-api/index.d.ts +8862 -0
  138. package/lib/common/base.converter.d.ts +16 -17
  139. package/lib/common/base.converter.js +12 -14
  140. package/lib/common/base.service.d.ts +1 -1
  141. package/lib/common/base.service.js +6 -36
  142. package/lib/services/attachments/attachments.service.d.ts +1 -2
  143. package/lib/services/attachments/attachments.service.js +7 -7
  144. package/lib/services/autotests/autotests.converter.d.ts +2 -3
  145. package/lib/services/autotests/autotests.converter.js +0 -5
  146. package/lib/services/autotests/autotests.service.d.ts +1 -2
  147. package/lib/services/autotests/autotests.service.js +11 -44
  148. package/lib/services/testresults/testresults.converter.d.ts +4 -5
  149. package/lib/services/testresults/testresults.converter.js +0 -15
  150. package/lib/services/testresults/testresults.service.d.ts +2 -3
  151. package/lib/services/testresults/testresults.service.js +16 -44
  152. package/lib/services/testresults/testresults.type.d.ts +1 -1
  153. package/lib/services/testruns/testruns.converter.d.ts +12 -13
  154. package/lib/services/testruns/testruns.converter.js +19 -8
  155. package/lib/services/testruns/testruns.service.d.ts +1 -2
  156. package/lib/services/testruns/testruns.service.js +13 -46
  157. package/package.json +7 -5
@@ -0,0 +1,67 @@
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
+ * API
11
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
12
+ *
13
+ * The version of the OpenAPI document: adapters
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
+ * Enum class WorkItemPriorityModel.
24
+ * @enum {}
25
+ * @readonly
26
+ */
27
+ class WorkItemPriorityModel {
28
+ /**
29
+ * value: "Lowest"
30
+ * @const
31
+ */
32
+ "Lowest" = "Lowest";
33
+
34
+ /**
35
+ * value: "Low"
36
+ * @const
37
+ */
38
+ "Low" = "Low";
39
+
40
+ /**
41
+ * value: "Medium"
42
+ * @const
43
+ */
44
+ "Medium" = "Medium";
45
+
46
+ /**
47
+ * value: "High"
48
+ * @const
49
+ */
50
+ "High" = "High";
51
+
52
+ /**
53
+ * value: "Highest"
54
+ * @const
55
+ */
56
+ "Highest" = "Highest";
57
+
58
+ /**
59
+ * Returns a <code>WorkItemPriorityModel</code> enum value from a Javascript object name.
60
+ * @param {Object} data The plain JavaScript object containing the name of the enum value.
61
+ * @return {module:model/WorkItemPriorityModel} The enum <code>WorkItemPriorityModel</code> value.
62
+ */
63
+ static constructFromObject(object) {
64
+ return object;
65
+ }
66
+ }
67
+ exports.default = WorkItemPriorityModel;
@@ -0,0 +1,90 @@
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 _WorkItemFilterApiModel = _interopRequireDefault(require("./WorkItemFilterApiModel"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
+ /**
11
+ * API
12
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
13
+ *
14
+ * The version of the OpenAPI document: adapters
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
+ * The WorkItemSelectApiModel model module.
25
+ * @module model/WorkItemSelectApiModel
26
+ * @version 1.0.0
27
+ */
28
+ class WorkItemSelectApiModel {
29
+ /**
30
+ * Constructs a new <code>WorkItemSelectApiModel</code>.
31
+ * @alias module:model/WorkItemSelectApiModel
32
+ * @param filter {module:model/WorkItemFilterApiModel}
33
+ */
34
+ constructor(filter) {
35
+ WorkItemSelectApiModel.initialize(this, filter);
36
+ }
37
+
38
+ /**
39
+ * Initializes the fields of this object.
40
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
41
+ * Only for internal use.
42
+ */
43
+ static initialize(obj, filter) {
44
+ obj['filter'] = filter;
45
+ }
46
+
47
+ /**
48
+ * Constructs a <code>WorkItemSelectApiModel</code> from a plain JavaScript object, optionally creating a new instance.
49
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
50
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
51
+ * @param {module:model/WorkItemSelectApiModel} obj Optional instance to populate.
52
+ * @return {module:model/WorkItemSelectApiModel} The populated <code>WorkItemSelectApiModel</code> instance.
53
+ */
54
+ static constructFromObject(data, obj) {
55
+ if (data) {
56
+ obj = obj || new WorkItemSelectApiModel();
57
+ if (data.hasOwnProperty('filter')) {
58
+ obj['filter'] = _ApiClient.default.convertToType(data['filter'], _WorkItemFilterApiModel.default);
59
+ }
60
+ }
61
+ return obj;
62
+ }
63
+
64
+ /**
65
+ * Validates the JSON data with respect to <code>WorkItemSelectApiModel</code>.
66
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
67
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>WorkItemSelectApiModel</code>.
68
+ */
69
+ static validateJSON(data) {
70
+ // check to make sure all required properties are present in the JSON string
71
+ for (const property of WorkItemSelectApiModel.RequiredProperties) {
72
+ if (!data.hasOwnProperty(property)) {
73
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
74
+ }
75
+ }
76
+ // validate the optional field `filter`
77
+ if (data['filter']) {
78
+ // data not null
79
+ _WorkItemFilterApiModel.default.validateJSON(data['filter']);
80
+ }
81
+ return true;
82
+ }
83
+ }
84
+ WorkItemSelectApiModel.RequiredProperties = ["filter"];
85
+
86
+ /**
87
+ * @member {module:model/WorkItemFilterApiModel} filter
88
+ */
89
+ WorkItemSelectApiModel.prototype['filter'] = undefined;
90
+ var _default = exports.default = WorkItemSelectApiModel;
@@ -0,0 +1,316 @@
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 _IterationApiResult = _interopRequireDefault(require("./IterationApiResult"));
9
+ var _LinkShortApiResult = _interopRequireDefault(require("./LinkShortApiResult"));
10
+ var _WorkItemPriorityModel = _interopRequireDefault(require("./WorkItemPriorityModel"));
11
+ var _WorkItemSourceTypeModel = _interopRequireDefault(require("./WorkItemSourceTypeModel"));
12
+ var _WorkItemStates = _interopRequireDefault(require("./WorkItemStates"));
13
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
14
+ /**
15
+ * API
16
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
17
+ *
18
+ * The version of the OpenAPI document: adapters
19
+ *
20
+ *
21
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
22
+ * https://openapi-generator.tech
23
+ * Do not edit the class manually.
24
+ *
25
+ */
26
+
27
+ /**
28
+ * The WorkItemShortApiResult model module.
29
+ * @module model/WorkItemShortApiResult
30
+ * @version 1.0.0
31
+ */
32
+ class WorkItemShortApiResult {
33
+ /**
34
+ * Constructs a new <code>WorkItemShortApiResult</code>.
35
+ * @alias module:model/WorkItemShortApiResult
36
+ * @param id {String} Work Item internal unique identifier
37
+ * @param name {String} Work Item name
38
+ * @param entityTypeName {String} Work Item type. Possible values: CheckLists, SharedSteps, TestCases
39
+ * @param projectId {String} Project unique identifier
40
+ * @param sectionId {String} Identifier of Section where Work Item is located
41
+ * @param sectionName {String} Section name of Work Item
42
+ * @param isAutomated {Boolean} Boolean flag determining whether Work Item is automated
43
+ * @param globalId {Number} Work Item global identifier
44
+ * @param duration {Number} Work Item duration
45
+ * @param state {module:model/WorkItemStates} The current state of Work Item
46
+ * @param priority {module:model/WorkItemPriorityModel} Work Item priority level
47
+ * @param sourceType {module:model/WorkItemSourceTypeModel} Work Item priority level
48
+ * @param isDeleted {Boolean} Flag determining whether Work Item is deleted
49
+ * @param iterations {Array.<module:model/IterationApiResult>} Set of iterations related to Work Item
50
+ * @param links {Array.<module:model/LinkShortApiResult>} Set of links related to Work Item
51
+ */
52
+ constructor(id, name, entityTypeName, projectId, sectionId, sectionName, isAutomated, globalId, duration, state, priority, sourceType, isDeleted, iterations, links) {
53
+ WorkItemShortApiResult.initialize(this, id, name, entityTypeName, projectId, sectionId, sectionName, isAutomated, globalId, duration, state, priority, sourceType, isDeleted, iterations, links);
54
+ }
55
+
56
+ /**
57
+ * Initializes the fields of this object.
58
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
59
+ * Only for internal use.
60
+ */
61
+ static initialize(obj, id, name, entityTypeName, projectId, sectionId, sectionName, isAutomated, globalId, duration, state, priority, sourceType, isDeleted, iterations, links) {
62
+ obj['id'] = id;
63
+ obj['name'] = name;
64
+ obj['entityTypeName'] = entityTypeName;
65
+ obj['projectId'] = projectId;
66
+ obj['sectionId'] = sectionId;
67
+ obj['sectionName'] = sectionName;
68
+ obj['isAutomated'] = isAutomated;
69
+ obj['globalId'] = globalId;
70
+ obj['duration'] = duration;
71
+ obj['state'] = state;
72
+ obj['priority'] = priority;
73
+ obj['sourceType'] = sourceType;
74
+ obj['isDeleted'] = isDeleted;
75
+ obj['iterations'] = iterations;
76
+ obj['links'] = links;
77
+ }
78
+
79
+ /**
80
+ * Constructs a <code>WorkItemShortApiResult</code> from a plain JavaScript object, optionally creating a new instance.
81
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
82
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
83
+ * @param {module:model/WorkItemShortApiResult} obj Optional instance to populate.
84
+ * @return {module:model/WorkItemShortApiResult} The populated <code>WorkItemShortApiResult</code> instance.
85
+ */
86
+ static constructFromObject(data, obj) {
87
+ if (data) {
88
+ obj = obj || new WorkItemShortApiResult();
89
+ if (data.hasOwnProperty('id')) {
90
+ obj['id'] = _ApiClient.default.convertToType(data['id'], 'String');
91
+ }
92
+ if (data.hasOwnProperty('name')) {
93
+ obj['name'] = _ApiClient.default.convertToType(data['name'], 'String');
94
+ }
95
+ if (data.hasOwnProperty('entityTypeName')) {
96
+ obj['entityTypeName'] = _ApiClient.default.convertToType(data['entityTypeName'], 'String');
97
+ }
98
+ if (data.hasOwnProperty('projectId')) {
99
+ obj['projectId'] = _ApiClient.default.convertToType(data['projectId'], 'String');
100
+ }
101
+ if (data.hasOwnProperty('sectionId')) {
102
+ obj['sectionId'] = _ApiClient.default.convertToType(data['sectionId'], 'String');
103
+ }
104
+ if (data.hasOwnProperty('sectionName')) {
105
+ obj['sectionName'] = _ApiClient.default.convertToType(data['sectionName'], 'String');
106
+ }
107
+ if (data.hasOwnProperty('isAutomated')) {
108
+ obj['isAutomated'] = _ApiClient.default.convertToType(data['isAutomated'], 'Boolean');
109
+ }
110
+ if (data.hasOwnProperty('globalId')) {
111
+ obj['globalId'] = _ApiClient.default.convertToType(data['globalId'], 'Number');
112
+ }
113
+ if (data.hasOwnProperty('duration')) {
114
+ obj['duration'] = _ApiClient.default.convertToType(data['duration'], 'Number');
115
+ }
116
+ if (data.hasOwnProperty('attributes')) {
117
+ obj['attributes'] = _ApiClient.default.convertToType(data['attributes'], {
118
+ 'String': Object
119
+ });
120
+ }
121
+ if (data.hasOwnProperty('state')) {
122
+ obj['state'] = _ApiClient.default.convertToType(data['state'], _WorkItemStates.default);
123
+ }
124
+ if (data.hasOwnProperty('priority')) {
125
+ obj['priority'] = _ApiClient.default.convertToType(data['priority'], _WorkItemPriorityModel.default);
126
+ }
127
+ if (data.hasOwnProperty('sourceType')) {
128
+ obj['sourceType'] = _ApiClient.default.convertToType(data['sourceType'], _WorkItemSourceTypeModel.default);
129
+ }
130
+ if (data.hasOwnProperty('isDeleted')) {
131
+ obj['isDeleted'] = _ApiClient.default.convertToType(data['isDeleted'], 'Boolean');
132
+ }
133
+ if (data.hasOwnProperty('tagNames')) {
134
+ obj['tagNames'] = _ApiClient.default.convertToType(data['tagNames'], ['String']);
135
+ }
136
+ if (data.hasOwnProperty('iterations')) {
137
+ obj['iterations'] = _ApiClient.default.convertToType(data['iterations'], [_IterationApiResult.default]);
138
+ }
139
+ if (data.hasOwnProperty('links')) {
140
+ obj['links'] = _ApiClient.default.convertToType(data['links'], [_LinkShortApiResult.default]);
141
+ }
142
+ }
143
+ return obj;
144
+ }
145
+
146
+ /**
147
+ * Validates the JSON data with respect to <code>WorkItemShortApiResult</code>.
148
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
149
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>WorkItemShortApiResult</code>.
150
+ */
151
+ static validateJSON(data) {
152
+ // check to make sure all required properties are present in the JSON string
153
+ for (const property of WorkItemShortApiResult.RequiredProperties) {
154
+ if (!data.hasOwnProperty(property)) {
155
+ throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
156
+ }
157
+ }
158
+ // ensure the json data is a string
159
+ if (data['id'] && !(typeof data['id'] === 'string' || data['id'] instanceof String)) {
160
+ throw new Error("Expected the field `id` to be a primitive type in the JSON string but got " + data['id']);
161
+ }
162
+ // ensure the json data is a string
163
+ if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) {
164
+ throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']);
165
+ }
166
+ // ensure the json data is a string
167
+ if (data['entityTypeName'] && !(typeof data['entityTypeName'] === 'string' || data['entityTypeName'] instanceof String)) {
168
+ throw new Error("Expected the field `entityTypeName` to be a primitive type in the JSON string but got " + data['entityTypeName']);
169
+ }
170
+ // ensure the json data is a string
171
+ if (data['projectId'] && !(typeof data['projectId'] === 'string' || data['projectId'] instanceof String)) {
172
+ throw new Error("Expected the field `projectId` to be a primitive type in the JSON string but got " + data['projectId']);
173
+ }
174
+ // ensure the json data is a string
175
+ if (data['sectionId'] && !(typeof data['sectionId'] === 'string' || data['sectionId'] instanceof String)) {
176
+ throw new Error("Expected the field `sectionId` to be a primitive type in the JSON string but got " + data['sectionId']);
177
+ }
178
+ // ensure the json data is a string
179
+ if (data['sectionName'] && !(typeof data['sectionName'] === 'string' || data['sectionName'] instanceof String)) {
180
+ throw new Error("Expected the field `sectionName` to be a primitive type in the JSON string but got " + data['sectionName']);
181
+ }
182
+ // ensure the json data is an array
183
+ if (!Array.isArray(data['tagNames'])) {
184
+ throw new Error("Expected the field `tagNames` to be an array in the JSON data but got " + data['tagNames']);
185
+ }
186
+ if (data['iterations']) {
187
+ // data not null
188
+ // ensure the json data is an array
189
+ if (!Array.isArray(data['iterations'])) {
190
+ throw new Error("Expected the field `iterations` to be an array in the JSON data but got " + data['iterations']);
191
+ }
192
+ // validate the optional field `iterations` (array)
193
+ for (const item of data['iterations']) {
194
+ _IterationApiResult.default.validateJSON(item);
195
+ }
196
+ ;
197
+ }
198
+ if (data['links']) {
199
+ // data not null
200
+ // ensure the json data is an array
201
+ if (!Array.isArray(data['links'])) {
202
+ throw new Error("Expected the field `links` to be an array in the JSON data but got " + data['links']);
203
+ }
204
+ // validate the optional field `links` (array)
205
+ for (const item of data['links']) {
206
+ _LinkShortApiResult.default.validateJSON(item);
207
+ }
208
+ ;
209
+ }
210
+ return true;
211
+ }
212
+ }
213
+ WorkItemShortApiResult.RequiredProperties = ["id", "name", "entityTypeName", "projectId", "sectionId", "sectionName", "isAutomated", "globalId", "duration", "state", "priority", "sourceType", "isDeleted", "iterations", "links"];
214
+
215
+ /**
216
+ * Work Item internal unique identifier
217
+ * @member {String} id
218
+ */
219
+ WorkItemShortApiResult.prototype['id'] = undefined;
220
+
221
+ /**
222
+ * Work Item name
223
+ * @member {String} name
224
+ */
225
+ WorkItemShortApiResult.prototype['name'] = undefined;
226
+
227
+ /**
228
+ * Work Item type. Possible values: CheckLists, SharedSteps, TestCases
229
+ * @member {String} entityTypeName
230
+ */
231
+ WorkItemShortApiResult.prototype['entityTypeName'] = undefined;
232
+
233
+ /**
234
+ * Project unique identifier
235
+ * @member {String} projectId
236
+ */
237
+ WorkItemShortApiResult.prototype['projectId'] = undefined;
238
+
239
+ /**
240
+ * Identifier of Section where Work Item is located
241
+ * @member {String} sectionId
242
+ */
243
+ WorkItemShortApiResult.prototype['sectionId'] = undefined;
244
+
245
+ /**
246
+ * Section name of Work Item
247
+ * @member {String} sectionName
248
+ */
249
+ WorkItemShortApiResult.prototype['sectionName'] = undefined;
250
+
251
+ /**
252
+ * Boolean flag determining whether Work Item is automated
253
+ * @member {Boolean} isAutomated
254
+ */
255
+ WorkItemShortApiResult.prototype['isAutomated'] = undefined;
256
+
257
+ /**
258
+ * Work Item global identifier
259
+ * @member {Number} globalId
260
+ */
261
+ WorkItemShortApiResult.prototype['globalId'] = undefined;
262
+
263
+ /**
264
+ * Work Item duration
265
+ * @member {Number} duration
266
+ */
267
+ WorkItemShortApiResult.prototype['duration'] = undefined;
268
+
269
+ /**
270
+ * Work Item attributes
271
+ * @member {Object.<String, Object>} attributes
272
+ */
273
+ WorkItemShortApiResult.prototype['attributes'] = undefined;
274
+
275
+ /**
276
+ * The current state of Work Item
277
+ * @member {module:model/WorkItemStates} state
278
+ */
279
+ WorkItemShortApiResult.prototype['state'] = undefined;
280
+
281
+ /**
282
+ * Work Item priority level
283
+ * @member {module:model/WorkItemPriorityModel} priority
284
+ */
285
+ WorkItemShortApiResult.prototype['priority'] = undefined;
286
+
287
+ /**
288
+ * Work Item priority level
289
+ * @member {module:model/WorkItemSourceTypeModel} sourceType
290
+ */
291
+ WorkItemShortApiResult.prototype['sourceType'] = undefined;
292
+
293
+ /**
294
+ * Flag determining whether Work Item is deleted
295
+ * @member {Boolean} isDeleted
296
+ */
297
+ WorkItemShortApiResult.prototype['isDeleted'] = undefined;
298
+
299
+ /**
300
+ * Array of tag names of Work Item
301
+ * @member {Array.<String>} tagNames
302
+ */
303
+ WorkItemShortApiResult.prototype['tagNames'] = undefined;
304
+
305
+ /**
306
+ * Set of iterations related to Work Item
307
+ * @member {Array.<module:model/IterationApiResult>} iterations
308
+ */
309
+ WorkItemShortApiResult.prototype['iterations'] = undefined;
310
+
311
+ /**
312
+ * Set of links related to Work Item
313
+ * @member {Array.<module:model/LinkShortApiResult>} links
314
+ */
315
+ WorkItemShortApiResult.prototype['links'] = undefined;
316
+ var _default = exports.default = WorkItemShortApiResult;
@@ -0,0 +1,49 @@
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
+ * API
11
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
12
+ *
13
+ * The version of the OpenAPI document: adapters
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
+ * Enum class WorkItemSourceTypeModel.
24
+ * @enum {}
25
+ * @readonly
26
+ */
27
+ class WorkItemSourceTypeModel {
28
+ /**
29
+ * value: "Manual"
30
+ * @const
31
+ */
32
+ "Manual" = "Manual";
33
+
34
+ /**
35
+ * value: "AI"
36
+ * @const
37
+ */
38
+ "AI" = "AI";
39
+
40
+ /**
41
+ * Returns a <code>WorkItemSourceTypeModel</code> enum value from a Javascript object name.
42
+ * @param {Object} data The plain JavaScript object containing the name of the enum value.
43
+ * @return {module:model/WorkItemSourceTypeModel} The enum <code>WorkItemSourceTypeModel</code> value.
44
+ */
45
+ static constructFromObject(object) {
46
+ return object;
47
+ }
48
+ }
49
+ exports.default = WorkItemSourceTypeModel;
@@ -0,0 +1,55 @@
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
+ * API
11
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
12
+ *
13
+ * The version of the OpenAPI document: adapters
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
+ * Enum class WorkItemStateApiModel.
24
+ * @enum {}
25
+ * @readonly
26
+ */
27
+ class WorkItemStateApiModel {
28
+ /**
29
+ * value: "NeedsWork"
30
+ * @const
31
+ */
32
+ "NeedsWork" = "NeedsWork";
33
+
34
+ /**
35
+ * value: "NotReady"
36
+ * @const
37
+ */
38
+ "NotReady" = "NotReady";
39
+
40
+ /**
41
+ * value: "Ready"
42
+ * @const
43
+ */
44
+ "Ready" = "Ready";
45
+
46
+ /**
47
+ * Returns a <code>WorkItemStateApiModel</code> enum value from a Javascript object name.
48
+ * @param {Object} data The plain JavaScript object containing the name of the enum value.
49
+ * @return {module:model/WorkItemStateApiModel} The enum <code>WorkItemStateApiModel</code> value.
50
+ */
51
+ static constructFromObject(object) {
52
+ return object;
53
+ }
54
+ }
55
+ exports.default = WorkItemStateApiModel;
@@ -0,0 +1,55 @@
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
+ * API
11
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
12
+ *
13
+ * The version of the OpenAPI document: adapters
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
+ * Enum class WorkItemStates.
24
+ * @enum {}
25
+ * @readonly
26
+ */
27
+ class WorkItemStates {
28
+ /**
29
+ * value: "NeedsWork"
30
+ * @const
31
+ */
32
+ "NeedsWork" = "NeedsWork";
33
+
34
+ /**
35
+ * value: "NotReady"
36
+ * @const
37
+ */
38
+ "NotReady" = "NotReady";
39
+
40
+ /**
41
+ * value: "Ready"
42
+ * @const
43
+ */
44
+ "Ready" = "Ready";
45
+
46
+ /**
47
+ * Returns a <code>WorkItemStates</code> enum value from a Javascript object name.
48
+ * @param {Object} data The plain JavaScript object containing the name of the enum value.
49
+ * @return {module:model/WorkItemStates} The enum <code>WorkItemStates</code> value.
50
+ */
51
+ static constructFromObject(object) {
52
+ return object;
53
+ }
54
+ }
55
+ exports.default = WorkItemStates;
@@ -0,0 +1,55 @@
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
+ * API
11
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
12
+ *
13
+ * The version of the OpenAPI document: adapters
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
+ * Enum class WorkItemTypeModel.
24
+ * @enum {}
25
+ * @readonly
26
+ */
27
+ class WorkItemTypeModel {
28
+ /**
29
+ * value: "TestCases"
30
+ * @const
31
+ */
32
+ "TestCases" = "TestCases";
33
+
34
+ /**
35
+ * value: "CheckLists"
36
+ * @const
37
+ */
38
+ "CheckLists" = "CheckLists";
39
+
40
+ /**
41
+ * value: "SharedSteps"
42
+ * @const
43
+ */
44
+ "SharedSteps" = "SharedSteps";
45
+
46
+ /**
47
+ * Returns a <code>WorkItemTypeModel</code> enum value from a Javascript object name.
48
+ * @param {Object} data The plain JavaScript object containing the name of the enum value.
49
+ * @return {module:model/WorkItemTypeModel} The enum <code>WorkItemTypeModel</code> value.
50
+ */
51
+ static constructFromObject(object) {
52
+ return object;
53
+ }
54
+ }
55
+ exports.default = WorkItemTypeModel;