itoolkit 1.0.1 → 1.0.2

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 (46) hide show
  1. package/README.md +5 -0
  2. package/lib/CommandCall.js +2 -16
  3. package/lib/Connection.js +2 -16
  4. package/lib/Deprecated.js +2 -22
  5. package/lib/ProgramCall.js +2 -16
  6. package/lib/itoolkit.js +2 -16
  7. package/lib/transports/httpTransport.js +2 -16
  8. package/lib/transports/idbTransport.js +2 -16
  9. package/lib/transports/odbcTransport.js +2 -16
  10. package/lib/transports/sshTransport.js +2 -16
  11. package/package.json +11 -5
  12. package/.eslintrc.js +0 -39
  13. package/.gitattributes +0 -2
  14. package/.readthedocs.yml +0 -16
  15. package/CHANGELOG.md +0 -228
  16. package/contributors.txt +0 -2
  17. package/test/README.md +0 -44
  18. package/test/functional/CommandCallFunctional.js +0 -87
  19. package/test/functional/ProgramCallFunctional.js +0 -106
  20. package/test/functional/checkObjectExists.js +0 -193
  21. package/test/functional/checkVersion.js +0 -17
  22. package/test/functional/config.js +0 -35
  23. package/test/functional/deprecated/commandsFunctional.js +0 -108
  24. package/test/functional/deprecated/iDataQueueFunctional.js +0 -103
  25. package/test/functional/deprecated/iNetworkFunctional.js +0 -159
  26. package/test/functional/deprecated/iObjFunctional.js +0 -349
  27. package/test/functional/deprecated/iPgmFunctional.js +0 -104
  28. package/test/functional/deprecated/iProdFunctional.js +0 -160
  29. package/test/functional/deprecated/iSqlFunctional.js +0 -453
  30. package/test/functional/deprecated/iUserSpaceFunctional.js +0 -138
  31. package/test/functional/deprecated/iWorkFunctional.js +0 -238
  32. package/test/functional/iDataQueueFunctional.js +0 -83
  33. package/test/functional/iNetworkFunctional.js +0 -131
  34. package/test/functional/iObjFunctional.js +0 -326
  35. package/test/functional/iProdFunctional.js +0 -134
  36. package/test/functional/iSqlFunctional.js +0 -448
  37. package/test/functional/iUserSpaceFunctional.js +0 -134
  38. package/test/functional/iWorkFunctional.js +0 -215
  39. package/test/unit/CommandCallUnit.js +0 -87
  40. package/test/unit/ConnectionUnit.js +0 -188
  41. package/test/unit/ProgamCallUnit.js +0 -281
  42. package/test/unit/deprecated/commandsUnit.js +0 -87
  43. package/test/unit/deprecated/iConnUnit.js +0 -158
  44. package/test/unit/deprecated/iPgmUnit.js +0 -211
  45. package/test/unit/deprecated/iSqlUnit.js +0 -441
  46. package/test/unit/deprecated/xmlToJsonUnit.js +0 -200
@@ -1,326 +0,0 @@
1
- // Copyright (c) International Business Machines Corp. 2019
2
-
3
- // Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
4
- // associated documentation files (the "Software"), to deal in the Software without restriction,
5
- // including without limitation the rights to use, copy, modify, merge, publish, distribute,
6
- // sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
7
- // furnished to do so, subject to the following conditions:
8
-
9
- // The above copyright notice and this permission notice shall be included in all copies or
10
- // substantial portions of the Software.
11
-
12
- // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
13
- // NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
14
- // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
15
- // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16
- // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
17
-
18
- /* eslint-disable new-cap */
19
-
20
- const { expect } = require('chai');
21
- const { Connection, iObj } = require('../../lib/itoolkit');
22
- const { config, printConfig } = require('./config');
23
-
24
- describe('iObj Functional Tests', function () {
25
- before(function () {
26
- printConfig();
27
- });
28
-
29
- describe('retrUsrAuth', function () {
30
- it('returns uses\'s authority for an object ', function (done) {
31
- const connection = new Connection(config);
32
-
33
- const obj = new iObj(connection);
34
-
35
- obj.retrUsrAuth('*PUBLIC', '*PGM', 'XMLCGI', 'QXMLSERV', (error, output) => {
36
- expect(error).to.equal(null);
37
- expect(output).to.be.an('Object');
38
- expect(output).to.have.a.property('Object_authority_/_Data_authority');
39
- expect(output).to.have.a.property('Authorization_list_management');
40
- expect(output).to.have.a.property('Object_operational');
41
- expect(output).to.have.a.property('Object_management');
42
- expect(output).to.have.a.property('Object_existence');
43
- expect(output).to.have.a.property('Data_read');
44
- expect(output).to.have.a.property('Data_add');
45
- expect(output).to.have.a.property('Data_update');
46
- expect(output).to.have.a.property('Data_delete');
47
- expect(output).to.have.a.property('Authorization_list');
48
- expect(output).to.have.a.property('Authority_source');
49
- expect(output).to.have.a.property('Some_adopted_authority');
50
- expect(output).to.have.a.property('Adopted_object_authority');
51
- expect(output).to.have.a.property('Adopted_authorization_list_management');
52
- expect(output).to.have.a.property('Adopted_object_operational');
53
- expect(output).to.have.a.property('Adopted_object_management');
54
- expect(output).to.have.a.property('Adopted_object_existence');
55
- expect(output).to.have.a.property('Adopted_data_read');
56
- expect(output).to.have.a.property('Adopted_data_add');
57
- expect(output).to.have.a.property('Adopted_data_update');
58
- expect(output).to.have.a.property('Adopted_data_delete');
59
- expect(output).to.have.a.property('Adopted_data_execute');
60
- expect(output).to.have.a.property('Adopted_object_alter');
61
- expect(output).to.have.a.property('Adopted_object_reference');
62
- expect(output).to.have.a.property('Data_execute');
63
- expect(output).to.have.a.property('Object_alter');
64
- expect(output).to.have.a.property('Object_reference');
65
- expect(output).to.have.a.property('ASP_device_name_of_library');
66
- expect(output).to.have.a.property('ASP_device_name_of_object');
67
- expect(output).to.have.a.property('Offset_to_group_information_table');
68
- expect(output).to.have.a.property('Number_of_group_table_entries_returned');
69
- done();
70
- });
71
- });
72
- });
73
-
74
- describe('rtrCmdInfo', function () {
75
- it('returns command info', function (done) {
76
- const connection = new Connection(config);
77
-
78
- const obj = new iObj(connection);
79
-
80
- obj.retrCmdInfo('CRTLIB', '*LIBL', (error, output) => {
81
- expect(error).to.equal(null);
82
- expect(output).to.be.an('Object');
83
- expect(output).to.have.a.property('Command_name');
84
- expect(output).to.have.a.property('Command_library_name');
85
- expect(output).to.have.a.property('Command_processing_program_or_proxy_target_command');
86
- expect(output).to.have.a.property('Command_processing_program\'s_or_proxy_target_command\'s_library_name');
87
- expect(output).to.have.a.property('Source_file_name');
88
- expect(output).to.have.a.property('Source_file_library_name');
89
- expect(output).to.have.a.property('Source_file_member_name');
90
- expect(output).to.have.a.property('Validity_check_program_name');
91
- expect(output).to.have.a.property('Validity_check_program_library_name');
92
- expect(output).to.have.a.property('Mode_information');
93
- expect(output).to.have.a.property('Where_allowed_to_run');
94
- expect(output).to.have.a.property('Allow_limited_user');
95
- expect(output).to.have.a.property('Maximum_positional_parameters');
96
- expect(output).to.have.a.property('Prompt_message_file_name');
97
- expect(output).to.have.a.property('Prompt_message_file_library_name');
98
- expect(output).to.have.a.property('Message_file_name');
99
- expect(output).to.have.a.property('Message_file_library_name');
100
- expect(output).to.have.a.property('Help_panel_group_name');
101
- expect(output).to.have.a.property('Help_panel_group_library_name');
102
- expect(output).to.have.a.property('Help_identifier');
103
- expect(output).to.have.a.property('Search_index_name');
104
- expect(output).to.have.a.property('Search_index_library_name');
105
- expect(output).to.have.a.property('Current_library');
106
- expect(output).to.have.a.property('Product_library');
107
- expect(output).to.have.a.property('Prompt_override_program_name');
108
- expect(output).to.have.a.property('Prompt_override_program_library_name');
109
- expect(output).to.have.a.property('Restricted_to_target_release');
110
- expect(output).to.have.a.property('Text_description');
111
- expect(output).to.have.a.property('Command_processing_program_call_state');
112
- expect(output).to.have.a.property('Validity_check_program_call_state');
113
- expect(output).to.have.a.property('Prompt_override_program_call_state');
114
- expect(output).to.have.a.property('Offset_to_help_bookshelf_information');
115
- expect(output).to.have.a.property('Length_of_help_bookshelf_information');
116
- expect(output).to.have.a.property('Coded_character_set_ID_(CCSID)');
117
- expect(output).to.have.a.property('Enabled_for_GUI_indicator');
118
- expect(output).to.have.a.property('Threadsafe_indicator');
119
- expect(output).to.have.a.property('Multithreaded_job_action');
120
- expect(output).to.have.a.property('Proxy_command_indicator');
121
- expect(output).to.have.a.property('Prompt_message_file_text_indicator');
122
- done();
123
- });
124
- });
125
- });
126
-
127
- describe('retrPgmInfo', function () {
128
- it('returns program info', function (done) {
129
- const connection = new Connection(config);
130
-
131
- const obj = new iObj(connection);
132
-
133
- obj.retrPgmInfo('XMLCGI', 'QXMLSERV', (error, output) => {
134
- expect(error).to.equal(null);
135
- expect(output).to.be.an('Object');
136
- expect(output).to.have.a.property('Program_name');
137
- expect(output).to.have.a.property('Program_library_name');
138
- expect(output).to.have.a.property('Program_owner');
139
- expect(output).to.have.a.property('Program_attribute');
140
- expect(output).to.have.a.property('Creation_date_and_time');
141
- expect(output).to.have.a.property('Source_file_name');
142
- expect(output).to.have.a.property('Source_file_library_name');
143
- expect(output).to.have.a.property('Source_file_member_name');
144
- expect(output).to.have.a.property('Source_file_updated_date_and_time');
145
- expect(output).to.have.a.property('Observable_information');
146
- expect(output).to.have.a.property('User_profile_option');
147
- expect(output).to.have.a.property('Use_adopted_authority');
148
- expect(output).to.have.a.property('Log_commands');
149
- expect(output).to.have.a.property('Allow_RTVCLSRC');
150
- expect(output).to.have.a.property('Fix_decimal_data');
151
- expect(output).to.have.a.property('Text_description');
152
- expect(output).to.have.a.property('Type_of_program');
153
- expect(output).to.have.a.property('Teraspace_storage-enabled_program');
154
- expect(output).to.have.a.property('Minimum_number_of_parameters');
155
- expect(output).to.have.a.property('Maximum_number_of_parameters');
156
- expect(output).to.have.a.property('Program_size');
157
- expect(output).to.have.a.property('Associated_space_size');
158
- expect(output).to.have.a.property('Static_storage_size');
159
- expect(output).to.have.a.property('Automatic_storage_size');
160
- expect(output).to.have.a.property('Number_of_MI_instructions');
161
- expect(output).to.have.a.property('Number_of_MI_ODT_entries');
162
- expect(output).to.have.a.property('Program_state');
163
- expect(output).to.have.a.property('Compiler_identification');
164
- expect(output).to.have.a.property('Earliest_release_program_can_run');
165
- expect(output).to.have.a.property('Sort_sequence_table_name');
166
- expect(output).to.have.a.property('Sort_sequence_table_library_name');
167
- expect(output).to.have.a.property('Language_identifier');
168
- expect(output).to.have.a.property('Program_domain');
169
- expect(output).to.have.a.property('Conversion_required');
170
- expect(output).to.have.a.property('Conversion_details');
171
- expect(output).to.have.a.property('Optimization');
172
- expect(output).to.have.a.property('Paging_pool');
173
- expect(output).to.have.a.property('Update_program_automatic_storage_area_(PASA)');
174
- expect(output).to.have.a.property('Clear_program_automatic_storage_area_(PASA)');
175
- expect(output).to.have.a.property('Paging_amount');
176
- expect(output).to.have.a.property('Program_entry_procedure_module');
177
- expect(output).to.have.a.property('Program_entry_procedure_module_library');
178
- expect(output).to.have.a.property('Activation_group_attribute');
179
- expect(output).to.have.a.property('Observable_information_compressed');
180
- expect(output).to.have.a.property('Run-time_information_compressed');
181
- expect(output).to.have.a.property('Release_program_created_on');
182
- expect(output).to.have.a.property('Shared_activation_group');
183
- expect(output).to.have.a.property('Allow_update');
184
- expect(output).to.have.a.property('Program_CCSID');
185
- expect(output).to.have.a.property('Number_of_modules');
186
- expect(output).to.have.a.property('Number_of_service_programs');
187
- expect(output).to.have.a.property('Number_of_copyrights');
188
- expect(output).to.have.a.property('Number_of_unresolved_references');
189
- expect(output).to.have.a.property('Release_program_created_for');
190
- expect(output).to.have.a.property('Allow_static_storage_reinitialization');
191
- expect(output).to.have.a.property('All_creation_data');
192
- expect(output).to.have.a.property('Allow_bound_*SRVPGM_library_name_update');
193
- expect(output).to.have.a.property('Profiling_data');
194
- expect(output).to.have.a.property('Teraspace_storage_enabled_modules');
195
- expect(output).to.have.a.property('Storage_model');
196
- expect(output).to.have.a.property('Uses_argument_optimization_(ARGOPT)');
197
- done();
198
- });
199
- });
200
- });
201
-
202
- describe('retrSrvPgmInfo', function () {
203
- it('returns service program info', function (done) {
204
- const connection = new Connection(config);
205
-
206
- const obj = new iObj(connection);
207
-
208
- obj.retrSrvPgmInfo('QZSRVSSL', 'QHTTPSVR', (error, output) => {
209
- expect(error).to.equal(null);
210
- expect(output).to.be.an('Object');
211
- expect(output).to.have.a.property('Service_program_name');
212
- expect(output).to.have.a.property('Service_program_name');
213
- expect(output).to.have.a.property('Service_program_owner');
214
- expect(output).to.have.a.property('Service_program_attribute');
215
- expect(output).to.have.a.property('Creation_date_and_time');
216
- expect(output).to.have.a.property('Export_source_file_name');
217
- expect(output).to.have.a.property('Export_source_file_library_name');
218
- expect(output).to.have.a.property('Export_source_file_member_name');
219
- expect(output).to.have.a.property('Activation_group_attribute');
220
- expect(output).to.have.a.property('Current_export_signature');
221
- expect(output).to.have.a.property('User_profile');
222
- expect(output).to.have.a.property('Observable_information_compressed');
223
- expect(output).to.have.a.property('Run-time_information_compressed');
224
- expect(output).to.have.a.property('Run-time_information_compressed');
225
- expect(output).to.have.a.property('Service_program_CCSID');
226
- expect(output).to.have.a.property('Number_of_modules');
227
- expect(output).to.have.a.property('Number_of_service_programs');
228
- expect(output).to.have.a.property('Number_of_copyrights');
229
- expect(output).to.have.a.property('Text_description');
230
- expect(output).to.have.a.property('Shared_activation_group');
231
- expect(output).to.have.a.property('Allow_update');
232
- expect(output).to.have.a.property('Number_of_unresolved_references');
233
- expect(output).to.have.a.property('Use_adopted_authority');
234
- expect(output).to.have.a.property('Allow_bound_*SRVPGM_library_name_update');
235
- expect(output).to.have.a.property('Profiling_data');
236
- expect(output).to.have.a.property('Teraspace_storage_enabled_modules');
237
- expect(output).to.have.a.property('Storage_model');
238
- expect(output).to.have.a.property('Uses_argument_optimization_(ARGOPT)');
239
- expect(output).to.have.a.property('Service_program_state');
240
- expect(output).to.have.a.property('Service_program_domain');
241
- expect(output).to.have.a.property('Associated_space_size');
242
- expect(output).to.have.a.property('Static_storage_size');
243
- expect(output).to.have.a.property('Service_program_size');
244
- expect(output).to.have.a.property('Release_service_program_created_on');
245
- expect(output).to.have.a.property('Earliest_release_service_program_can_run');
246
- expect(output).to.have.a.property('Release_service_program_created_for');
247
- expect(output).to.have.a.property('Allow_static_storage_reinitialization');
248
- expect(output).to.have.a.property('Conversion_required');
249
- expect(output).to.have.a.property('All_creation_data');
250
- expect(output).to.have.a.property('Conversion_details');
251
- expect(output).to.have.a.property('Paging_pool');
252
- expect(output).to.have.a.property('Paging_amount');
253
- done();
254
- });
255
- });
256
- });
257
-
258
- describe('retrUserInfo', function () {
259
- it('returns specified user profile info', function (done) {
260
- const connection = new Connection(config);
261
-
262
- const obj = new iObj(connection);
263
-
264
- obj.retrUserInfo('QSYS', (error, output) => {
265
- expect(error).to.equal(null);
266
- expect(output).to.be.an('Object');
267
- expect(output).to.have.a.property('User_profile_name');
268
- expect(output).to.have.a.property('Previous_sign-on_date_and_time');
269
- expect(output).to.have.a.property('Sign-on_attempts_not_valid');
270
- expect(output).to.have.a.property('Status');
271
- expect(output).to.have.a.property('Password_change_date');
272
- expect(output).to.have.a.property('No_password_indicator');
273
- expect(output).to.have.a.property('Password_expiration_interval');
274
- expect(output).to.have.a.property('Date_password_expires');
275
- expect(output).to.have.a.property('Days_until_password_expires');
276
- expect(output).to.have.a.property('Set_password_to_expire');
277
- expect(output).to.have.a.property('Display_sign-on_information');
278
- expect(output).to.have.a.property('Local_password_management');
279
- expect(output).to.have.a.property('Block_password_change');
280
- done();
281
- });
282
- });
283
- });
284
-
285
- describe('retrUsrAuthToObj', function () {
286
- it(`retrieves info for users who are authorized to an object using ${config.transport} transpsort`, function (done) {
287
- const connection = new Connection(config);
288
-
289
- const obj = new iObj(connection);
290
-
291
- obj.retrUserAuthToObj('/home', (error, output) => {
292
- expect(error).to.equal(null);
293
- expect(output).to.be.an('Object');
294
- expect(output).to.have.a.property('Profile_name');
295
- expect(output).to.have.a.property('User_or_group_indicator');
296
- expect(output).to.have.a.property('Data_authority');
297
- expect(output).to.have.a.property('Authorization_list_management');
298
- expect(output).to.have.a.property('Object_management');
299
- expect(output).to.have.a.property('Object_existence');
300
- expect(output).to.have.a.property('Object_alter');
301
- expect(output).to.have.a.property('Object_reference');
302
- expect(output).to.have.a.property('Object_operational');
303
- expect(output).to.have.a.property('Data_read');
304
- expect(output).to.have.a.property('Data_add');
305
- expect(output).to.have.a.property('Data_update');
306
- expect(output).to.have.a.property('Data_delete');
307
- expect(output).to.have.a.property('Data_execute');
308
- done();
309
- });
310
- });
311
- });
312
-
313
- describe('addToLibraryList', function () {
314
- it('appends lib to user\'s lib list', function (done) {
315
- const connection = new Connection(config);
316
-
317
- const obj = new iObj(connection);
318
-
319
- obj.addToLibraryList('QHTTPSVR', (error, output) => {
320
- expect(error).to.equal(null);
321
- expect(output).to.be.a('boolean').and.to.equal(true);
322
- done();
323
- });
324
- });
325
- });
326
- });
@@ -1,134 +0,0 @@
1
- // Copyright (c) International Business Machines Corp. 2019
2
-
3
- // Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
4
- // associated documentation files (the "Software"), to deal in the Software without restriction,
5
- // including without limitation the rights to use, copy, modify, merge, publish, distribute,
6
- // sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
7
- // furnished to do so, subject to the following conditions:
8
-
9
- // The above copyright notice and this permission notice shall be included in all copies or
10
- // substantial portions of the Software.
11
-
12
- // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT
13
- // NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
14
- // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
15
- // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16
- // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
17
-
18
- /* eslint-disable new-cap */
19
-
20
- const { expect } = require('chai');
21
- const { Connection, iProd } = require('../../lib/itoolkit');
22
- const { config, printConfig } = require('./config');
23
-
24
- describe('iProd Functional Tests', function () {
25
- before(function () {
26
- printConfig();
27
- });
28
-
29
- describe('getPTFInfo', function () {
30
- it('returns info for specified ptf', function (done) {
31
- const connection = new Connection(config);
32
-
33
- const prod = new iProd(connection);
34
-
35
- prod.getPTFInfo('SI67726', (error, ptf) => {
36
- expect(error).to.equal(null);
37
- expect(ptf).to.be.an('Object');
38
- expect(ptf).to.have.a.property('Product_ID');
39
- expect(ptf).to.have.a.property('PTF_ID');
40
- expect(ptf).to.have.a.property('Release_level');
41
- expect(ptf).to.have.a.property('Product_option');
42
- expect(ptf).to.have.a.property('Load_ID');
43
- expect(ptf).to.have.a.property('Loaded_status');
44
- expect(ptf).to.have.a.property('Cover_letter_status');
45
- expect(ptf).to.have.a.property('On-order_status');
46
- expect(ptf).to.have.a.property('Save_file_status');
47
- expect(ptf).to.have.a.property('File_name');
48
- expect(ptf).to.have.a.property('File_library_name');
49
- expect(ptf).to.have.a.property('PTF_type');
50
- expect(ptf).to.have.a.property('IPL_action');
51
- expect(ptf).to.have.a.property('Action_pending');
52
- expect(ptf).to.have.a.property('Action_required');
53
- expect(ptf).to.have.a.property('PTF_is_released');
54
- expect(ptf).to.have.a.property('Target_release');
55
- expect(ptf).to.have.a.property('Superseding_PTF');
56
- expect(ptf).to.have.a.property('Current_IPL_source');
57
- expect(ptf).to.have.a.property('Minimum_level');
58
- expect(ptf).to.have.a.property('Maximum_level');
59
- expect(ptf).to.have.a.property('Format_information_available');
60
- expect(ptf).to.have.a.property('Status_date_and_time');
61
- expect(ptf).to.have.a.property('Licensed_Internal_Code_group');
62
- expect(ptf).to.have.a.property('Superseded_by_PTF_ID');
63
- expect(ptf).to.have.a.property('Current_server_IPL_source');
64
- expect(ptf).to.have.a.property('Server_IPL_required');
65
- expect(ptf).to.have.a.property('Creation_date_and_time');
66
- expect(ptf).to.have.a.property('Technology_refresh_PTF');
67
- done();
68
- });
69
- });
70
- });
71
-
72
- describe('getProductInfo', function () {
73
- it('returns info for specified product', function (done) {
74
- const connection = new Connection(config);
75
-
76
- const prod = new iProd(connection);
77
-
78
- prod.getProductInfo('5770DG1', (error, product) => {
79
- expect(error).to.equal(null);
80
- expect(product).to.be.an('Object');
81
- expect(product).to.have.a.property('Product_ID');
82
- expect(product).to.have.a.property('Release_level');
83
- expect(product).to.have.a.property('Product_option');
84
- expect(product).to.have.a.property('Load_ID');
85
- expect(product).to.have.a.property('Symbolic_load_state');
86
- expect(product).to.have.a.property('Load_error_indicator');
87
- expect(product).to.have.a.property('Load_state');
88
- expect(product).to.have.a.property('Supported_flag');
89
- expect(product).to.have.a.property('Registration_type');
90
- expect(product).to.have.a.property('Registration_value');
91
- expect(product).to.have.a.property('Offset_to_additional_information');
92
- expect(product).to.have.a.property('Primary_language_load_identifier');
93
- expect(product).to.have.a.property('Minimum_target_release');
94
- expect(product).to.have.a.property('Minimum_VRM_of_*BASE_required_by_option');
95
- expect(product).to.have.a.property('Requirements_met_between_base_and_option_value');
96
- expect(product).to.have.a.property('Level');
97
- done();
98
- });
99
- });
100
- });
101
-
102
- // REST transport currently failing with 414 URI Too Long response code
103
- // The requested URL's length exceeds the capacity limit for this server
104
- describe('getInstalledProducts', function () {
105
- // eslint-disable-next-line func-names
106
- it('returns info for installed products', function (done) {
107
- const connection = new Connection(config);
108
-
109
- const prod = new iProd(connection);
110
-
111
- prod.getInstalledProducts((error, products) => {
112
- expect(error).to.equal(null);
113
- expect(products).to.be.an('Array');
114
- expect(products.length).to.be.greaterThan(0);
115
-
116
- products.forEach((product) => {
117
- expect(product).to.be.an('Object');
118
- expect(product).to.have.a.property('Product_ID');
119
- expect(product).to.have.a.property('Product_option');
120
- expect(product).to.have.a.property('Release_level');
121
- expect(product).to.have.a.property('Description_text_message_ID');
122
- expect(product).to.have.a.property('Description_text_object_name');
123
- expect(product).to.have.a.property('Description_text_library_name');
124
- expect(product).to.have.a.property('Installed_flag');
125
- expect(product).to.have.a.property('Supported_flag');
126
- expect(product).to.have.a.property('Registration_type');
127
- expect(product).to.have.a.property('Registration_value');
128
- expect(product).to.have.a.property('Description_text');
129
- });
130
- done();
131
- });
132
- });
133
- });
134
- });