@@ -94,95 +94,71 @@ def __init__(self, server_url, devKey, **args):
94
94
@decoApiCallAddDevKey
95
95
@decoMakerApiCallWithArgs (['testplanid' ])
96
96
def getLatestBuildForTestPlan (self ):
97
- """ getLatestBuildForTestPlan: Gets the latest build by choosing the
98
- maximum build id for a specific test plan
99
- positional args: testplanid
100
- optional args : --- """
97
+ """ Gets the latest build by choosing the maximum build id for a specific test plan """
101
98
102
99
@decoApiCallAddDevKey
103
100
@decoMakerApiCallWithArgs (['testplanid' ],
104
101
['testcaseid' , 'testcaseexternalid' ])
105
102
def getLastExecutionResult (self ):
106
- """ getLastExecutionResult:
107
- Gets the result of LAST EXECUTION for a particular testcase
108
- on a test plan, but WITHOUT checking for a particular build
109
- positional args: testplanid
110
- optional args : testcaseid, testcaseexternalid """
103
+ """ Gets the result of LAST EXECUTION for a particular testcase on a test plan,
104
+ but WITHOUT checking for a particular build """
111
105
112
106
@decoApiCallWithoutArgs
113
107
def sayHello (self ):
114
- """ sayHello: Lets you see if the server is up and running
115
- positional args: ---
116
- optional args : --- """
108
+ """ Lets you see if the server is up and running """
117
109
118
110
def ping (self ):
119
111
""" alias for methodAPI sayHello """
120
112
return self .sayHello ()
121
113
122
114
@decoMakerApiCallWithArgs (['str' ])
123
115
def repeat (self ):
124
- """ repeat: Repeats a message back
125
- positional args: str
126
- optional args : --- """
116
+ """ Repeats a message back """
127
117
128
118
@decoApiCallWithoutArgs
129
119
def about (self ):
130
- """ about: Gives basic information about the API
131
- positional args: ---
132
- optional args : --- """
120
+ """ Gives basic information about the API """
133
121
134
122
@decoApiCallAddDevKey
135
123
@decoMakerApiCallWithArgs (['testplanid' , 'buildname' ],
136
124
['buildnotes' ])
137
125
def createBuild (self ):
138
- """ createBuild: Creates a new build for a specific test plan
139
- positional args: testplanid, buildname
140
- optional args : buildnotes """
126
+ """ Creates a new build for a specific test plan """
141
127
142
128
@decoApiCallAddDevKey
143
129
@decoMakerApiCallWithArgs ()
144
130
def getProjects (self ):
145
- """ getProjects: Gets a list of all projects
146
- positional args: ---
147
- optional args : --- """
131
+ """ Gets a list of all projects """
148
132
149
133
@decoMakerApiCallReplaceTLResponseError ()
150
134
@decoApiCallAddDevKey
151
135
@decoMakerApiCallWithArgs (['testprojectid' ])
152
136
def getProjectTestPlans (self ):
153
- """ getProjectTestPlans: Gets a list of test plans within a project
154
- positional args: testprojectid
155
- optional args : ---
137
+ """ Gets a list of test plans within a project
156
138
157
139
returns an empty list, if no testplan is assigned """
158
140
159
141
@decoMakerApiCallReplaceTLResponseError ()
160
142
@decoApiCallAddDevKey
161
143
@decoMakerApiCallWithArgs (['testplanid' ])
162
144
def getBuildsForTestPlan (self ):
163
- """ getBuildsForTestPlan : Gets a list of builds within a test plan
164
- positional args: testplanid
165
- optional args : ---
145
+ """ Gets a list of builds within a test plan
166
146
167
147
returns an empty list, if no build is assigned """
168
148
169
149
@decoMakerApiCallReplaceTLResponseError ()
170
150
@decoApiCallAddDevKey
171
151
@decoMakerApiCallWithArgs (['testplanid' ])
172
152
def getTestSuitesForTestPlan (self ):
173
- """ getTestSuitesForTestPlan : List test suites within a test plan alphabetically
174
- positional args: testplanid
175
- optional args : ---
153
+ """ List test suites within a test plan alphabetically
176
154
177
155
returns an empty list, if no build is assigned """
178
156
179
157
@decoApiCallAddDevKey
180
158
@decoMakerApiCallWithArgs (['testprojectname' , 'testcaseprefix' ],
181
159
['notes' , 'active' , 'public' , 'options' ])
182
160
def createTestProject (self ):
183
- """ createTestProject : Create a test project
184
- positional args: testprojectname, testcaseprefix
185
- optional args : notes, active, public, options
161
+ """ Create a test project
186
162
187
163
options : dictionary with keys
188
164
requirementsEnabled, testPriorityEnabled,
@@ -193,9 +169,7 @@ def createTestProject(self):
193
169
@decoApiCallAddDevKey
194
170
@decoMakerApiCallWithArgs (['testsuiteid' ], ['deep' , 'details' ])
195
171
def getTestCasesForTestSuite (self ):
196
- """ getTestCasesForTestSuite : List test suites within a test plan alphabetically
197
- positional args: testsuiteid
198
- optional args : deep, details
172
+ """ List test suites within a test plan alphabetically
199
173
200
174
details - default is 'simple',
201
175
use 'full' if you want to get summary,steps & expected_results
@@ -207,9 +181,7 @@ def getTestCasesForTestSuite(self):
207
181
@decoMakerApiCallWithArgs (['testcasename' ],
208
182
['testsuitename' , 'testprojectname' , 'testcasepathname' ])
209
183
def getTestCaseIDByName (self ):
210
- """ getTestCaseIDByName : Find a test case by its name
211
- positional args: testcasename,
212
- optional args : testsuitename, testprojectname, testcasepathname
184
+ """ Find a test case by its name
213
185
214
186
testcasepathname : Full test case path name,
215
187
starts with test project name , pieces separator -> ::
@@ -222,11 +194,7 @@ def getTestCaseIDByName(self):
222
194
['preconditions' , 'importance' , 'execution' , 'order' ,
223
195
'internalid' , 'checkduplicatedname' , 'actiononduplicatedname' ])
224
196
def createTestCase (self ):
225
- """ createTestCase: Create a test case
226
- positional args: testcasename, testsuiteid, testprojectid, authorlogin,
227
- summary, steps
228
- optional args : preconditions, importance, execution, order, internalid,
229
- checkduplicatedname, actiononduplicatedname
197
+ """ Create a test case
230
198
231
199
steps is a list with dictionaries , example
232
200
[{'step_number' : 1, 'actions' : "action A" ,
@@ -243,16 +211,15 @@ def createTestCase(self):
243
211
'platformid' , 'platformname' , 'notes' , 'guess' , 'bugid' ,
244
212
'customfields' , 'overwrite' ])
245
213
def reportTCResult (self ):
246
- """ reportTCResult : Reports a result for a single test case
247
- positional args: testplanid, status
248
- optional args (variations): testcaseid - testcaseexternalid
249
- buildid - buildname
250
- platformid - platformname
251
- optional args : notes, guess, bugid, customfields, overwrite
214
+ """ Reports a result for a single test case
215
+
216
+ args variations: testcaseid - testcaseexternalid
217
+ buildid - buildname
218
+ platformid - platformname
252
219
253
220
customfields : dictionary with customfields names + values
254
221
VERY IMPORTANT: value must be formatted in the way it's written to db
255
- """
222
+ """
256
223
257
224
# /**
258
225
# * turn on/off testMode
@@ -270,26 +237,18 @@ def reportTCResult(self):
270
237
['testcaseid' , 'keywordid' , 'keywords' , 'executed' , 'assignedto' ,
271
238
'executestatus' , 'executiontype' , 'getstepinfo' , 'details' ])
272
239
def getTestCasesForTestPlan (self ):
273
- """ getTestCasesForTestPlan : List test cases linked to a test plan
274
- positional args: testplanid
275
- optional args : testcaseid, keywordid, keywords, executed, assignedto,
276
- executestatus, executiontype, getstepinfo, details
240
+ """ List test cases linked to a test plan
277
241
278
242
details - default is 'full',
279
243
'simple', 'details' ??
280
-
281
244
282
245
returns an empty list, if no build is assigned """
283
246
284
247
@decoApiCallAddDevKey
285
248
@decoMakerApiCallWithArgs (['testcaseexternalid' , 'version' , 'testprojectid' ,
286
249
'customfieldname' ], ['details' ])
287
250
def getTestCaseCustomFieldDesignValue (self ):
288
- """ getTestCaseCustomFieldDesignValue :
289
- Gets value of a Custom Field with scope='design' for a given Test case
290
- positional args: testcaseexternalid, version, testprojectid,
291
- customfieldname
292
- optional args : details
251
+ """ Gets value of a Custom Field with scope='design' for a given Test case
293
252
294
253
details = changes output information
295
254
null or 'value' => just value
@@ -319,12 +278,8 @@ def getTestCaseCustomFieldDesignValue(self):
319
278
@decoApiCallAddDevKey
320
279
@decoMakerApiCallWithArgs (['testprojectid' ])
321
280
def getFirstLevelTestSuitesForTestProject (self ):
322
- """ getFirstLevelTestSuitesForTestProject : get set of test suites
323
- AT TOP LEVEL of tree on a Test Project
281
+ """ get set of test suites AT TOP LEVEL of tree on a Test Project
324
282
325
- positional args: testprojectid
326
- optional args : ---
327
-
328
283
returns an empty list, if no suite is assigned (api error 7008)
329
284
- details see comments for decoMakerApiCallReplaceTLResponseError """
330
285
@@ -347,43 +302,32 @@ def getFirstLevelTestSuitesForTestProject(self):
347
302
@decoApiCallAddDevKey
348
303
@decoMakerApiCallWithArgs ([], ['testcaseid' , 'testcaseexternalid' ])
349
304
def getTestCaseAttachments (self ):
350
- """ getTestCaseAttachments: Gets attachments for specified test case.
305
+ """ Gets attachments for specified test case.
351
306
The attachment file content is Base64 encoded. To save the file to disk
352
- in client, Base64 decode the content and write file in binary mode.
353
- positional args: ---
354
- optional args : testcaseid, testcaseexternalid """
307
+ in client, Base64 decode the content and write file in binary mode. """
355
308
356
309
@decoApiCallAddDevKey
357
310
@decoMakerApiCallWithArgs (['testprojectid' , 'testsuitename' , 'details' ],
358
311
['parentid' , 'order' , 'checkduplicatedname' ,
359
312
'actiononduplicatedname' ])
360
313
def createTestSuite (self ):
361
- """ createTestSuite: create a test suite
362
- positional args: testprojectid, testsuitename, details
363
- optional args : parentid, order, checkduplicatedname,
364
- actiononduplicatedname """
314
+ """ create a test suite """
365
315
366
316
@decoApiCallAddDevKey
367
317
@decoMakerApiCallWithArgs (['testprojectname' ])
368
318
def getTestProjectByName (self ):
369
- """ getTestProjectByName: Gets info about target test project
370
- positional args: testprojectname
371
- optional args : --- """
319
+ """ Gets info about target test project """
372
320
373
321
@decoApiCallAddDevKey
374
322
@decoMakerApiCallWithArgs (['testprojectname' , 'testplanname' ])
375
323
def getTestPlanByName (self ):
376
- """ getTestPlanByName: Gets info about target test project
377
- positional args: testprojectname, testplanname
378
- optional args : --- """
324
+ """ Gets info about target test project """
379
325
380
326
381
327
@decoApiCallAddDevKey
382
328
@decoMakerApiCallWithArgs ([], ['testcaseid' , 'testcaseexternalid' , 'version' ])
383
329
def getTestCase (self ):
384
- """ getTestCase: get test case specification using external or internal id
385
- positional args: ---
386
- optional args : testcaseid, testcaseexternalid, version
330
+ """ get test case specification using external or internal id
387
331
388
332
attention - becareful with testcaseexternalid - it must inlcude an '-'.
389
333
otherwise TL returns
@@ -393,18 +337,13 @@ def getTestCase(self):
393
337
@decoMakerApiCallWithArgs (['testplanname' , 'testprojectname' ],
394
338
['note' , 'active' , 'public' ])
395
339
def createTestPlan (self ):
396
- """ createTestPlan : create a test plan
397
- positional args: testplanname, testprojectname
398
- optional args : notes, active, public """
340
+ """ create a test plan """
399
341
400
342
401
343
@decoApiCallAddDevKey
402
344
@decoMakerApiCallWithArgs (['nodeid' ])
403
345
def getFullPath (self ):
404
- """ getFullPath : Gets full path from the given node till the top using
405
- nodes_hierarchy_table
406
- positional args: nodeid
407
- optional args : ---
346
+ """ Gets full path from the given node till the top using nodes_hierarchy_table
408
347
409
348
nodeid = can be just a single id or a list with ids
410
349
ATTENTION: id must be an integer. """
@@ -428,55 +367,39 @@ def getFullPath(self):
428
367
@decoApiCallAddDevKey
429
368
@decoMakerApiCallWithArgs (['testsuiteid' ])
430
369
def getTestSuiteByID (self ):
431
- """ getTestSuiteByID : Return a TestSuite by ID
432
-
433
- positional args: testsuiteid
434
- optional args : --- """
435
-
370
+ """ Return a TestSuite by ID """
436
371
437
372
@decoMakerApiCallReplaceTLResponseError ()
438
373
@decoApiCallAddDevKey
439
374
@decoMakerApiCallWithArgs (['testsuiteid' ])
440
375
def getTestSuitesForTestSuite (self ):
441
- """ getTestSuitesForTestSuite : get list of TestSuites which are DIRECT
442
- children of a given TestSuite
443
- positional args: testsuiteid
444
- optional args : ---
376
+ """ get list of TestSuites which are DIRECT children of a given TestSuite
445
377
446
378
returns an empty list, if no platform is assigned """
447
379
448
380
@decoMakerApiCallReplaceTLResponseError (3041 )
449
381
@decoApiCallAddDevKey
450
382
@decoMakerApiCallWithArgs (['testplanid' ])
451
383
def getTestPlanPlatforms (self ):
452
- """ getTestPlanPlatforms : Returns the list of platforms associated to
453
- a given test plan
454
- positional args: testplanid
455
- optional args : ---
384
+ """ Returns the list of platforms associated to a given test plan
456
385
457
386
returns an empty list, if no platform is assigned (api error 3041)
458
387
- details see comments for decoMakerApiCallReplaceTLResponseError """
459
388
460
389
@decoApiCallAddDevKey
461
390
@decoMakerApiCallWithArgs (['testplanid' ])
462
391
def getTotalsForTestPlan (self ):
463
- """ getTotalsForTestPlan : Gets the summarized results grouped by platform.
464
- positional args: testplanid
465
- optional args : --- """
392
+ """ Gets the summarized results grouped by platform. """
466
393
467
394
@decoMakerApiCallWithArgs (['user' ])
468
395
def doesUserExist (self ):
469
- """ doesUserExist : Checks if user name exists
470
- positional args: user
471
- optional args : ---
396
+ """ Checks if user name exists
472
397
returns true if everything OK, otherwise error structure """
473
398
474
399
@decoApiCallAddDevKey
475
400
@decoMakerApiCallWithArgs (['devKey' ])
476
401
def checkDevKey (self ):
477
- """ checkDevKey : check if Developer Key exists
478
- positional args: ---
479
- optional args : ---
402
+ """ check if Developer Key exists
480
403
returns true if everything OK, otherwise error structure """
481
404
482
405
# /**
@@ -589,10 +512,8 @@ def checkDevKey(self):
589
512
@decoMakerApiCallWithArgs (['executionid' ],
590
513
['title' , 'description' , 'filename' , 'filetype' , 'content' ])
591
514
def uploadExecutionAttachment (self ):
592
- """ uploadExecutionAttachment: Uploads an attachment for an execution
593
- mandatory args: attachmentfile
594
- positional args: executionid
595
- optional args : title, description, filename, filetype, content
515
+ """ Uploads an attachment for an execution
516
+ mandatory non api args: attachmentfile
596
517
597
518
attachmentfile: python file descriptor pointing to the file
598
519
!Attention - on WINDOWS use binary mode for none text file
0 commit comments