aspose_slides_cloud 23.9.0 → 23.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (48) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -7
  3. data/README.md +4 -0
  4. data/aspose_slides_cloud.gemspec +0 -1
  5. data/docker-entrypoint.sh +1 -0
  6. data/lib/aspose_slides_cloud/api/slides_async_api.rb +273 -0
  7. data/lib/aspose_slides_cloud/api_client.rb +2 -1
  8. data/lib/aspose_slides_cloud/models/operation.rb +209 -0
  9. data/lib/aspose_slides_cloud/type_registry.rb +1 -0
  10. data/lib/aspose_slides_cloud/version.rb +1 -1
  11. data/lib/aspose_slides_cloud.rb +2 -0
  12. data/spec/api/slides_api_spec.rb +2016 -2016
  13. data/spec/api/slides_async_api_spec.rb +554 -0
  14. data/spec/spec_utils.rb +38 -7
  15. data/spec/use_cases/abstract_class_spec.rb +1 -1
  16. data/spec/use_cases/animation_spec.rb +28 -28
  17. data/spec/use_cases/async_api_spec.rb +82 -0
  18. data/spec/use_cases/chart_spec.rb +51 -51
  19. data/spec/use_cases/comment_spec.rb +17 -17
  20. data/spec/use_cases/create_spec.rb +22 -22
  21. data/spec/use_cases/font_spec.rb +24 -24
  22. data/spec/use_cases/header_footer_spec.rb +9 -9
  23. data/spec/use_cases/hyperlink_spec.rb +10 -10
  24. data/spec/use_cases/image_spec.rb +16 -16
  25. data/spec/use_cases/layout_slide_spec.rb +41 -41
  26. data/spec/use_cases/master_slide_spec.rb +40 -40
  27. data/spec/use_cases/math_spec.rb +15 -15
  28. data/spec/use_cases/merge_spec.rb +15 -15
  29. data/spec/use_cases/notes_slide_spec.rb +39 -39
  30. data/spec/use_cases/nullable_field_spec.rb +7 -7
  31. data/spec/use_cases/paragraph_spec.rb +38 -38
  32. data/spec/use_cases/pipeline_spec.rb +1 -1
  33. data/spec/use_cases/portion_spec.rb +34 -34
  34. data/spec/use_cases/property_spec.rb +38 -38
  35. data/spec/use_cases/section_spec.rb +16 -16
  36. data/spec/use_cases/shape_format_spec.rb +12 -12
  37. data/spec/use_cases/shape_spec.rb +87 -87
  38. data/spec/use_cases/slide_spec.rb +32 -32
  39. data/spec/use_cases/split_spec.rb +12 -12
  40. data/spec/use_cases/table_spec.rb +38 -38
  41. data/spec/use_cases/text_format_spec.rb +4 -4
  42. data/spec/use_cases/text_spec.rb +28 -28
  43. data/spec/use_cases/vba_spec.rb +10 -10
  44. data/spec/use_cases/watermark_spec.rb +36 -36
  45. data/testConfig.json +2 -1
  46. data/testRules.json +7 -0
  47. metadata +8 -24
  48. data/spec/use_cases/convert_spec.rb +0 -199
@@ -0,0 +1,554 @@
1
+ =begin
2
+ Copyright (c) 2019 Aspose Pty Ltd
3
+
4
+ Permission is hereby granted, free of charge, to any person obtaining a copy
5
+ of this software and associated documentation files (the "Software"), to deal
6
+ in the Software without restriction, including without limitation the rights
7
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
+ copies of the Software, and to permit persons to whom the Software is
9
+ furnished to do so, subject to the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be included in all
12
+ copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20
+ SOFTWARE.
21
+ =end
22
+
23
+ require 'spec_helper'
24
+ #require 'json'
25
+
26
+ # Unit tests for AsposeSlidesCloud::SlidesAsyncApi
27
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
28
+ # Please update as you see appropriate
29
+ describe 'SlidesAsyncApi' do
30
+
31
+ # unit tests for get_operation_result
32
+ # @param id
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [File]
35
+ describe 'get_operation_result test' do
36
+ it 'should work' do
37
+ paramid = AsposeSlidesCloud::SpecUtils.get_param_value('id', 'GetOperationResult', 'String')
38
+ AsposeSlidesCloud::SpecUtils.initialize('GetOperationResult', nil, nil)
39
+ o, c, _h = AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.get_operation_result_with_http_info(paramid)
40
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationResult', nil, nil, nil)
41
+ expect(c).to eq(code)
42
+ expect(o).not_to be_nil
43
+ end
44
+
45
+ it 'invalid id' do
46
+ paramid = AsposeSlidesCloud::SpecUtils.get_param_value('id', 'GetOperationResult', 'String')
47
+ paramid = AsposeSlidesCloud::SpecUtils.invalidize_param_value('id', 'GetOperationResult', paramid, 'String')
48
+ AsposeSlidesCloud::SpecUtils.initialize('GetOperationResult', 'id', paramid)
49
+ begin
50
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.get_operation_result_with_http_info(paramid)
51
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('GetOperationResult', 'id')
52
+ fail "An exception expected"
53
+ end
54
+ rescue AsposeSlidesCloud::ApiError => e
55
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationResult', 'id', paramid, 'String')
56
+ expect(e.code).to eq(code)
57
+ expect(e.response_body).to include(message)
58
+ rescue ArgumentError => e
59
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationResult', 'id', paramid, 'String')
60
+ expect(400).to eq(code)
61
+ expect(e.message).to include(message)
62
+ end
63
+ end
64
+ end
65
+
66
+ # unit tests for get_operation_status
67
+ # @param id
68
+ # @param [Hash] opts the optional parameters
69
+ # @return [Operation]
70
+ describe 'get_operation_status test' do
71
+ it 'should work' do
72
+ paramid = AsposeSlidesCloud::SpecUtils.get_param_value('id', 'GetOperationStatus', 'String')
73
+ AsposeSlidesCloud::SpecUtils.initialize('GetOperationStatus', nil, nil)
74
+ o, c, _h = AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.get_operation_status_with_http_info(paramid)
75
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationStatus', nil, nil, nil)
76
+ expect(c).to eq(code)
77
+ expect(o).not_to be_nil
78
+ end
79
+
80
+ it 'invalid id' do
81
+ paramid = AsposeSlidesCloud::SpecUtils.get_param_value('id', 'GetOperationStatus', 'String')
82
+ paramid = AsposeSlidesCloud::SpecUtils.invalidize_param_value('id', 'GetOperationStatus', paramid, 'String')
83
+ AsposeSlidesCloud::SpecUtils.initialize('GetOperationStatus', 'id', paramid)
84
+ begin
85
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.get_operation_status_with_http_info(paramid)
86
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('GetOperationStatus', 'id')
87
+ fail "An exception expected"
88
+ end
89
+ rescue AsposeSlidesCloud::ApiError => e
90
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationStatus', 'id', paramid, 'String')
91
+ expect(e.code).to eq(code)
92
+ expect(e.response_body).to include(message)
93
+ rescue ArgumentError => e
94
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('GetOperationStatus', 'id', paramid, 'String')
95
+ expect(400).to eq(code)
96
+ expect(e.message).to include(message)
97
+ end
98
+ end
99
+ end
100
+
101
+ # unit tests for start_convert
102
+ # @param document Document data.
103
+ # @param format
104
+ # @param [Hash] opts the optional parameters
105
+ # @option opts [String] :password
106
+ # @option opts [String] :storage
107
+ # @option opts [String] :fonts_folder
108
+ # @option opts [Integer[]] :slides
109
+ # @option opts [ExportOptions] :options
110
+ # @return [String]
111
+ describe 'start_convert test' do
112
+ it 'should work' do
113
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
114
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
115
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
116
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
117
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
118
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
119
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
120
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', nil, nil)
121
+ o, c, _h = AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
122
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', nil, nil, nil)
123
+ expect(c).to eq(code)
124
+ end
125
+
126
+ it 'invalid document' do
127
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
128
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
129
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
130
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
131
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
132
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
133
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
134
+ paramdocument = AsposeSlidesCloud::SpecUtils.invalidize_param_value('document', 'StartConvert', paramdocument, 'File')
135
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'document', paramdocument)
136
+ begin
137
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
138
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'document')
139
+ fail "An exception expected"
140
+ end
141
+ rescue AsposeSlidesCloud::ApiError => e
142
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'document', paramdocument, 'File')
143
+ expect(e.code).to eq(code)
144
+ expect(e.response_body).to include(message)
145
+ rescue ArgumentError => e
146
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'document', paramdocument, 'File')
147
+ expect(400).to eq(code)
148
+ expect(e.message).to include(message)
149
+ end
150
+ end
151
+
152
+ it 'invalid format' do
153
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
154
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
155
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
156
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
157
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
158
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
159
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
160
+ paramformat = AsposeSlidesCloud::SpecUtils.invalidize_param_value('format', 'StartConvert', paramformat, 'String')
161
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'format', paramformat)
162
+ begin
163
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
164
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'format')
165
+ fail "An exception expected"
166
+ end
167
+ rescue AsposeSlidesCloud::ApiError => e
168
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'format', paramformat, 'String')
169
+ expect(e.code).to eq(code)
170
+ expect(e.response_body).to include(message)
171
+ rescue ArgumentError => e
172
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'format', paramformat, 'String')
173
+ expect(400).to eq(code)
174
+ expect(e.message).to include(message)
175
+ end
176
+ end
177
+
178
+ it 'invalid password' do
179
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
180
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
181
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
182
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
183
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
184
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
185
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
186
+ parampassword = AsposeSlidesCloud::SpecUtils.invalidize_param_value('password', 'StartConvert', parampassword, 'String')
187
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'password', parampassword)
188
+ begin
189
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
190
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'password')
191
+ fail "An exception expected"
192
+ end
193
+ rescue AsposeSlidesCloud::ApiError => e
194
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'password', parampassword, 'String')
195
+ expect(e.code).to eq(code)
196
+ expect(e.response_body).to include(message)
197
+ rescue ArgumentError => e
198
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'password', parampassword, 'String')
199
+ expect(400).to eq(code)
200
+ expect(e.message).to include(message)
201
+ end
202
+ end
203
+
204
+ it 'invalid storage' do
205
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
206
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
207
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
208
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
209
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
210
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
211
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
212
+ paramstorage = AsposeSlidesCloud::SpecUtils.invalidize_param_value('storage', 'StartConvert', paramstorage, 'String')
213
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'storage', paramstorage)
214
+ begin
215
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
216
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'storage')
217
+ fail "An exception expected"
218
+ end
219
+ rescue AsposeSlidesCloud::ApiError => e
220
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'storage', paramstorage, 'String')
221
+ expect(e.code).to eq(code)
222
+ expect(e.response_body).to include(message)
223
+ rescue ArgumentError => e
224
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'storage', paramstorage, 'String')
225
+ expect(400).to eq(code)
226
+ expect(e.message).to include(message)
227
+ end
228
+ end
229
+
230
+ it 'invalid fonts_folder' do
231
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
232
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
233
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
234
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
235
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
236
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
237
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
238
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.invalidize_param_value('fontsFolder', 'StartConvert', paramfonts_folder, 'String')
239
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'fontsFolder', paramfonts_folder)
240
+ begin
241
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
242
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'fontsFolder')
243
+ fail "An exception expected"
244
+ end
245
+ rescue AsposeSlidesCloud::ApiError => e
246
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'fontsFolder', paramfonts_folder, 'String')
247
+ expect(e.code).to eq(code)
248
+ expect(e.response_body).to include(message)
249
+ rescue ArgumentError => e
250
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'fontsFolder', paramfonts_folder, 'String')
251
+ expect(400).to eq(code)
252
+ expect(e.message).to include(message)
253
+ end
254
+ end
255
+
256
+ it 'invalid slides' do
257
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
258
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
259
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
260
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
261
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
262
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
263
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
264
+ paramslides = AsposeSlidesCloud::SpecUtils.invalidize_param_value('slides', 'StartConvert', paramslides, 'Integer[]')
265
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'slides', paramslides)
266
+ begin
267
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
268
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'slides')
269
+ fail "An exception expected"
270
+ end
271
+ rescue AsposeSlidesCloud::ApiError => e
272
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'slides', paramslides, 'Integer[]')
273
+ expect(e.code).to eq(code)
274
+ expect(e.response_body).to include(message)
275
+ rescue ArgumentError => e
276
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'slides', paramslides, 'Integer[]')
277
+ expect(400).to eq(code)
278
+ expect(e.message).to include(message)
279
+ end
280
+ end
281
+
282
+ it 'invalid options' do
283
+ paramdocument = AsposeSlidesCloud::SpecUtils.get_param_value('document', 'StartConvert', 'File')
284
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartConvert', 'String')
285
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartConvert', 'String')
286
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartConvert', 'String')
287
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartConvert', 'String')
288
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartConvert', 'Integer[]')
289
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartConvert', 'ExportOptions')
290
+ paramoptions = AsposeSlidesCloud::SpecUtils.invalidize_param_value('options', 'StartConvert', paramoptions, 'ExportOptions')
291
+ AsposeSlidesCloud::SpecUtils.initialize('StartConvert', 'options', paramoptions)
292
+ begin
293
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_convert_with_http_info(paramdocument, paramformat, parampassword, paramstorage, paramfonts_folder, paramslides, paramoptions)
294
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartConvert', 'options')
295
+ fail "An exception expected"
296
+ end
297
+ rescue AsposeSlidesCloud::ApiError => e
298
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'options', paramoptions, 'ExportOptions')
299
+ expect(e.code).to eq(code)
300
+ expect(e.response_body).to include(message)
301
+ rescue ArgumentError => e
302
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartConvert', 'options', paramoptions, 'ExportOptions')
303
+ expect(400).to eq(code)
304
+ expect(e.message).to include(message)
305
+ end
306
+ end
307
+ end
308
+
309
+ # unit tests for start_download_presentation
310
+ # @param name
311
+ # @param format
312
+ # @param [Hash] opts the optional parameters
313
+ # @option opts [ExportOptions] :options
314
+ # @option opts [String] :password
315
+ # @option opts [String] :folder
316
+ # @option opts [String] :storage
317
+ # @option opts [String] :fonts_folder
318
+ # @option opts [Integer[]] :slides
319
+ # @return [String]
320
+ describe 'start_download_presentation test' do
321
+ it 'should work' do
322
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
323
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
324
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
325
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
326
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
327
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
328
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
329
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
330
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', nil, nil)
331
+ o, c, _h = AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
332
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', nil, nil, nil)
333
+ expect(c).to eq(code)
334
+ expect(o).not_to be_nil
335
+ end
336
+
337
+ it 'invalid name' do
338
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
339
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
340
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
341
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
342
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
343
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
344
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
345
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
346
+ paramname = AsposeSlidesCloud::SpecUtils.invalidize_param_value('name', 'StartDownloadPresentation', paramname, 'String')
347
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'name', paramname)
348
+ begin
349
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
350
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'name')
351
+ fail "An exception expected"
352
+ end
353
+ rescue AsposeSlidesCloud::ApiError => e
354
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'name', paramname, 'String')
355
+ expect(e.code).to eq(code)
356
+ expect(e.response_body).to include(message)
357
+ rescue ArgumentError => e
358
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'name', paramname, 'String')
359
+ expect(400).to eq(code)
360
+ expect(e.message).to include(message)
361
+ end
362
+ end
363
+
364
+ it 'invalid format' do
365
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
366
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
367
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
368
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
369
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
370
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
371
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
372
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
373
+ paramformat = AsposeSlidesCloud::SpecUtils.invalidize_param_value('format', 'StartDownloadPresentation', paramformat, 'String')
374
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'format', paramformat)
375
+ begin
376
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
377
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'format')
378
+ fail "An exception expected"
379
+ end
380
+ rescue AsposeSlidesCloud::ApiError => e
381
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'format', paramformat, 'String')
382
+ expect(e.code).to eq(code)
383
+ expect(e.response_body).to include(message)
384
+ rescue ArgumentError => e
385
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'format', paramformat, 'String')
386
+ expect(400).to eq(code)
387
+ expect(e.message).to include(message)
388
+ end
389
+ end
390
+
391
+ it 'invalid options' do
392
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
393
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
394
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
395
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
396
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
397
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
398
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
399
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
400
+ paramoptions = AsposeSlidesCloud::SpecUtils.invalidize_param_value('options', 'StartDownloadPresentation', paramoptions, 'ExportOptions')
401
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'options', paramoptions)
402
+ begin
403
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
404
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'options')
405
+ fail "An exception expected"
406
+ end
407
+ rescue AsposeSlidesCloud::ApiError => e
408
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'options', paramoptions, 'ExportOptions')
409
+ expect(e.code).to eq(code)
410
+ expect(e.response_body).to include(message)
411
+ rescue ArgumentError => e
412
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'options', paramoptions, 'ExportOptions')
413
+ expect(400).to eq(code)
414
+ expect(e.message).to include(message)
415
+ end
416
+ end
417
+
418
+ it 'invalid password' do
419
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
420
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
421
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
422
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
423
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
424
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
425
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
426
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
427
+ parampassword = AsposeSlidesCloud::SpecUtils.invalidize_param_value('password', 'StartDownloadPresentation', parampassword, 'String')
428
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'password', parampassword)
429
+ begin
430
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
431
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'password')
432
+ fail "An exception expected"
433
+ end
434
+ rescue AsposeSlidesCloud::ApiError => e
435
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'password', parampassword, 'String')
436
+ expect(e.code).to eq(code)
437
+ expect(e.response_body).to include(message)
438
+ rescue ArgumentError => e
439
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'password', parampassword, 'String')
440
+ expect(400).to eq(code)
441
+ expect(e.message).to include(message)
442
+ end
443
+ end
444
+
445
+ it 'invalid folder' do
446
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
447
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
448
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
449
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
450
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
451
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
452
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
453
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
454
+ paramfolder = AsposeSlidesCloud::SpecUtils.invalidize_param_value('folder', 'StartDownloadPresentation', paramfolder, 'String')
455
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'folder', paramfolder)
456
+ begin
457
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
458
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'folder')
459
+ fail "An exception expected"
460
+ end
461
+ rescue AsposeSlidesCloud::ApiError => e
462
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'folder', paramfolder, 'String')
463
+ expect(e.code).to eq(code)
464
+ expect(e.response_body).to include(message)
465
+ rescue ArgumentError => e
466
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'folder', paramfolder, 'String')
467
+ expect(400).to eq(code)
468
+ expect(e.message).to include(message)
469
+ end
470
+ end
471
+
472
+ it 'invalid storage' do
473
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
474
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
475
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
476
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
477
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
478
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
479
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
480
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
481
+ paramstorage = AsposeSlidesCloud::SpecUtils.invalidize_param_value('storage', 'StartDownloadPresentation', paramstorage, 'String')
482
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'storage', paramstorage)
483
+ begin
484
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
485
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'storage')
486
+ fail "An exception expected"
487
+ end
488
+ rescue AsposeSlidesCloud::ApiError => e
489
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'storage', paramstorage, 'String')
490
+ expect(e.code).to eq(code)
491
+ expect(e.response_body).to include(message)
492
+ rescue ArgumentError => e
493
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'storage', paramstorage, 'String')
494
+ expect(400).to eq(code)
495
+ expect(e.message).to include(message)
496
+ end
497
+ end
498
+
499
+ it 'invalid fonts_folder' do
500
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
501
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
502
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
503
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
504
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
505
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
506
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
507
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
508
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.invalidize_param_value('fontsFolder', 'StartDownloadPresentation', paramfonts_folder, 'String')
509
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'fontsFolder', paramfonts_folder)
510
+ begin
511
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
512
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'fontsFolder')
513
+ fail "An exception expected"
514
+ end
515
+ rescue AsposeSlidesCloud::ApiError => e
516
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'fontsFolder', paramfonts_folder, 'String')
517
+ expect(e.code).to eq(code)
518
+ expect(e.response_body).to include(message)
519
+ rescue ArgumentError => e
520
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'fontsFolder', paramfonts_folder, 'String')
521
+ expect(400).to eq(code)
522
+ expect(e.message).to include(message)
523
+ end
524
+ end
525
+
526
+ it 'invalid slides' do
527
+ paramname = AsposeSlidesCloud::SpecUtils.get_param_value('name', 'StartDownloadPresentation', 'String')
528
+ paramformat = AsposeSlidesCloud::SpecUtils.get_param_value('format', 'StartDownloadPresentation', 'String')
529
+ paramoptions = AsposeSlidesCloud::SpecUtils.get_param_value('options', 'StartDownloadPresentation', 'ExportOptions')
530
+ parampassword = AsposeSlidesCloud::SpecUtils.get_param_value('password', 'StartDownloadPresentation', 'String')
531
+ paramfolder = AsposeSlidesCloud::SpecUtils.get_param_value('folder', 'StartDownloadPresentation', 'String')
532
+ paramstorage = AsposeSlidesCloud::SpecUtils.get_param_value('storage', 'StartDownloadPresentation', 'String')
533
+ paramfonts_folder = AsposeSlidesCloud::SpecUtils.get_param_value('fontsFolder', 'StartDownloadPresentation', 'String')
534
+ paramslides = AsposeSlidesCloud::SpecUtils.get_param_value('slides', 'StartDownloadPresentation', 'Integer[]')
535
+ paramslides = AsposeSlidesCloud::SpecUtils.invalidize_param_value('slides', 'StartDownloadPresentation', paramslides, 'Integer[]')
536
+ AsposeSlidesCloud::SpecUtils.initialize('StartDownloadPresentation', 'slides', paramslides)
537
+ begin
538
+ AsposeSlidesCloud::SpecUtils.testSlidesAsyncApi.start_download_presentation_with_http_info(paramname, paramformat, paramoptions, parampassword, paramfolder, paramstorage, paramfonts_folder, paramslides)
539
+ unless AsposeSlidesCloud::SpecUtils.no_exception?('StartDownloadPresentation', 'slides')
540
+ fail "An exception expected"
541
+ end
542
+ rescue AsposeSlidesCloud::ApiError => e
543
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'slides', paramslides, 'Integer[]')
544
+ expect(e.code).to eq(code)
545
+ expect(e.response_body).to include(message)
546
+ rescue ArgumentError => e
547
+ code, message = AsposeSlidesCloud::SpecUtils.get_expected_error('StartDownloadPresentation', 'slides', paramslides, 'Integer[]')
548
+ expect(400).to eq(code)
549
+ expect(e.message).to include(message)
550
+ end
551
+ end
552
+ end
553
+
554
+ end