TestLinkClient 0.0.2 → 0.0.3
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.
- data/lib/TestLinkClient.rb +463 -29
- metadata +1 -1
data/lib/TestLinkClient.rb
CHANGED
@@ -3,6 +3,13 @@ require 'xmlrpc/client'
|
|
3
3
|
# Author:: Sadahiko Hantani (garyohosu@gmail.com)
|
4
4
|
# Copyright:: Copyright (c) 2008 Sadahiko Hantani
|
5
5
|
# License:: Distributes under GPL
|
6
|
+
#
|
7
|
+
# ���藚��
|
8
|
+
#- 0.01 2008/12/14 �V�K�쐬
|
9
|
+
#- 0.02 2008/12/15 �擪�Ƀo�C�i���������Ă����̂ŏC��
|
10
|
+
#- 0.03 2008/12/15 �R�����g��lj�
|
11
|
+
#
|
12
|
+
|
6
13
|
|
7
14
|
class TestLinkClient
|
8
15
|
#
|
@@ -46,6 +53,61 @@ class TestLinkClient
|
|
46
53
|
@devKey = dev_key
|
47
54
|
end
|
48
55
|
|
56
|
+
|
57
|
+
#
|
58
|
+
#=== �T�v
|
59
|
+
#
|
60
|
+
# reportTCResult(tpid,tcid,status,bid,notes,guess)
|
61
|
+
#
|
62
|
+
#=== ����
|
63
|
+
#
|
64
|
+
#+tpid+::
|
65
|
+
# �e�X�g�v��ID
|
66
|
+
#+tcid+::
|
67
|
+
# �e�X�g�P�[�XID
|
68
|
+
#+status+::
|
69
|
+
# �e�X�g���� p:���� f:���s b:�u���b�N
|
70
|
+
#+bid+::
|
71
|
+
# �r���hID(�I�v�V����)
|
72
|
+
#+notes+::
|
73
|
+
# �m�[�g(�I�v�V����)
|
74
|
+
#+guess+::
|
75
|
+
# (�I�v�V����)
|
76
|
+
#
|
77
|
+
#=== �߂�l
|
78
|
+
# ��
|
79
|
+
# [{"message"=>"Success!", "status"=>true, "id"=>"2"}]
|
80
|
+
#
|
81
|
+
#=== ��O
|
82
|
+
#
|
83
|
+
#=== �ڍ�
|
84
|
+
#
|
85
|
+
# �e�X�g���ʂ�o�^����
|
86
|
+
#
|
87
|
+
# message:���b�Z�[�W
|
88
|
+
# id:ID
|
89
|
+
# status:true ���� false ���s
|
90
|
+
#
|
91
|
+
#=== ��
|
92
|
+
#
|
93
|
+
# reportTCResult(tpid,bid,tcid,status) #=>[{"message"=>"Success!", "status"=>true, "id"=>"2"}]
|
94
|
+
#
|
95
|
+
def reportTCResult(tpid,tcid,status,bid=nil,notes=nil,guess=nil)
|
96
|
+
|
97
|
+
args = {"devKey"=>@devKey,"testcaseid"=>tcid.to_i,"testplanid"=>tpid,"status"=>status,"buildid"=>bid}
|
98
|
+
|
99
|
+
if bid then
|
100
|
+
args["buildid"] = bid
|
101
|
+
end
|
102
|
+
if notes then #string
|
103
|
+
args["notes"] = notes
|
104
|
+
end
|
105
|
+
if guess then #bool
|
106
|
+
args["guess"] = guess
|
107
|
+
end
|
108
|
+
ret = @server.call("tl.reportTCResult",args)
|
109
|
+
end
|
110
|
+
|
49
111
|
#
|
50
112
|
#=== �T�v
|
51
113
|
#
|
@@ -120,6 +182,46 @@ class TestLinkClient
|
|
120
182
|
ret = @server.call("tl.getProjectTestPlans",args)
|
121
183
|
end
|
122
184
|
|
185
|
+
|
186
|
+
#
|
187
|
+
#=== �T�v
|
188
|
+
#
|
189
|
+
# createBuild(testplanid,buildname,buildnotes)
|
190
|
+
#
|
191
|
+
#=== ����
|
192
|
+
#
|
193
|
+
#+testplanid+::
|
194
|
+
# �e�X�g�v��ID
|
195
|
+
#+buildname+::
|
196
|
+
# �r���h��
|
197
|
+
#+buildnotes+::
|
198
|
+
# �r���h�m�[�g
|
199
|
+
#
|
200
|
+
#=== �߂�l
|
201
|
+
# ��
|
202
|
+
# [{"message"=>"Success!", "status"=>true, "id"=>"4"}]
|
203
|
+
#
|
204
|
+
#=== ��O
|
205
|
+
#
|
206
|
+
#=== �ڍ�
|
207
|
+
#
|
208
|
+
# �e�X�g�v���W�F�N�gID,�r���h���A�r���h�m�[�g��n���ƐV�K�r���h������
|
209
|
+
# - :�r���hID
|
210
|
+
# name:�r���h��
|
211
|
+
# notes:�m�[�g
|
212
|
+
# id:�r���hID
|
213
|
+
# testproject_id:�e�X�g�v���W�F�N�gID
|
214
|
+
# active:�A�N�e�B�u���H
|
215
|
+
#
|
216
|
+
#=== ��
|
217
|
+
#
|
218
|
+
# createBuild(testplanid,buildname,buildnotes) #=>[{"message"=>"Success!", "status"=>true, "id"=>"2"}]
|
219
|
+
#
|
220
|
+
def createBuild(testplanid,buildname,buildnotes)
|
221
|
+
args = {"devKey"=>@devKey,"testplanid"=>testplanid,"buildname"=>buildname,"buildnotes"=>buildnotes}
|
222
|
+
ret = @server.call("tl.createBuild",args)
|
223
|
+
end
|
224
|
+
|
123
225
|
#
|
124
226
|
#=== �T�v
|
125
227
|
#
|
@@ -188,12 +290,14 @@ class TestLinkClient
|
|
188
290
|
#
|
189
291
|
#=== �T�v
|
190
292
|
#
|
191
|
-
#
|
293
|
+
# getTestCasesForTestSuite(tsid)
|
192
294
|
#
|
193
295
|
#=== ����
|
194
296
|
#
|
195
|
-
#+
|
196
|
-
# �e�X�g�
|
297
|
+
#+tsid+::
|
298
|
+
# �e�X�g�X�C�[�gID
|
299
|
+
#+deep+::
|
300
|
+
# �ċA�I�������s��(�I�v�V����) �f�t�H���g��True
|
197
301
|
#
|
198
302
|
#=== �߂�l
|
199
303
|
# ��
|
@@ -203,24 +307,128 @@ class TestLinkClient
|
|
203
307
|
#
|
204
308
|
#=== �ڍ�
|
205
309
|
#
|
206
|
-
# �e�X�g�
|
207
|
-
# name:�e�X�g�
|
208
|
-
# id
|
310
|
+
# �e�X�g�X�C�[�gID��n���ƃe�X�g�P�[�X�̏ڍ���Ԃ�
|
311
|
+
# name:�e�X�g�P�[�X��
|
312
|
+
# id:�e�X�g�P�[�XID
|
313
|
+
# node_type_id:
|
314
|
+
# parent_id:
|
315
|
+
# node_order:
|
209
316
|
#
|
210
317
|
#=== ��
|
211
318
|
#
|
212
|
-
#
|
319
|
+
# getTestCasesForTestSuite(tsid) #=>{"name"=>"testsuite1", "id"=>"36"}
|
213
320
|
#
|
214
|
-
def getTestCasesForTestSuite(ts)
|
215
|
-
args = {"devKey"=>@devKey,"testsuiteid"=>ts}
|
321
|
+
def getTestCasesForTestSuite(ts,deep=nil)
|
322
|
+
args = {"devKey"=>@devKey,"testsuiteid"=>ts}
|
323
|
+
|
324
|
+
if deep then #
|
325
|
+
args["deep"] = deep
|
326
|
+
end
|
327
|
+
|
216
328
|
ret = @server.call("tl.getTestCasesForTestSuite",args)
|
217
329
|
end
|
218
330
|
|
219
|
-
|
220
|
-
|
331
|
+
#
|
332
|
+
#=== �T�v
|
333
|
+
#
|
334
|
+
# getTestCasesForTestPlan(tpid,tcid,bldid,keyid,execid,assignedto,executestatus)
|
335
|
+
#
|
336
|
+
#=== ����
|
337
|
+
#
|
338
|
+
#+tpid+::�e�X�g�v��ID
|
339
|
+
#+tcid+::�e�X�g�P�[�XID�i�I�v�V�����j
|
340
|
+
#+bldid+::�r���hID�i�I�v�V�����j
|
341
|
+
#+keyid+::�L�[ID�i�I�v�V�����j
|
342
|
+
#+executed+::�i�I�v�V�����j
|
343
|
+
#+assignedto+::�i�I�v�V�����j
|
344
|
+
#+executestatus+::�i�I�v�V�����j
|
345
|
+
#
|
346
|
+
#=== �߂�l
|
347
|
+
# ��
|
348
|
+
#{"45"=>{"exec_status"=>"n", "status"=>"", "name"=>"testcase1", "assigner_id"=>"", "urgency"=>"2", "exec_id"=>"", "type"=>"", "exec_on_tplan"=>"", "executed"=>"", "external_id"=>"4", "z"=>"100", "tc_id"=>"45", "version"=>"1", "tcversion_id"=>"46", "execution_order"=>"40", "user_id"=>"", "feature_id"=>"19", "tcversion_number"=>"", "testsuite_id"=>"44", "active"=>"1"}, "41"=>{"exec_status"=>"p", "status"=>"", "name"=>"testcase3", "assigner_id"=>"", "urgency"=>"2", "exec_id"=>"42", "type"=>"", "exec_on_tplan"=>"43", "executed"=>"42", "external_id"=>"3", "z"=>"100", "tc_id"=>"41", "version"=>"1", "tcversion_id"=>"42", "execution_order"=>"30", "user_id"=>"", "feature_id"=>"18", "tcversion_number"=>"1", "testsuite_id"=>"36", "active"=>"1"}}
|
349
|
+
#=== ��O
|
350
|
+
#
|
351
|
+
#=== �ڍ�
|
352
|
+
#
|
353
|
+
# �e�X�g�v��ID��n���ƃe�X�g�P�[�X�̏ڍ���Ԃ�
|
354
|
+
# - :�e�X�g�P�[�XID
|
355
|
+
# exec_status:���s���� p or f or b
|
356
|
+
# status:
|
357
|
+
# name:�e�X�g�P�[�X��
|
358
|
+
# assigner_id:
|
359
|
+
# urgency:
|
360
|
+
# exec_id:
|
361
|
+
# type:
|
362
|
+
# exec_on_tplan:
|
363
|
+
# executed:
|
364
|
+
# external_id:
|
365
|
+
# z:
|
366
|
+
# tc_id:�e�X�g�P�[�XID
|
367
|
+
# version:�e�X�g�P�[�X�o�[�W����
|
368
|
+
# tcversion_id:�e�X�g�P�[�X�o�[�W����ID
|
369
|
+
# execution_order:
|
370
|
+
# user_id:
|
371
|
+
# feature_id:
|
372
|
+
# tcversion_number:
|
373
|
+
# testsuite_id:�e�X�g�X�C�[�gID
|
374
|
+
# active:�A�N�e�B�u���H
|
375
|
+
#
|
376
|
+
#=== ��
|
377
|
+
#
|
378
|
+
# getTestCasesForTestPlan(tpid) #=>{"45"=>{"exec_status"=>"n", "status"=>"", "name"=>"testcase1", "assigner_id"=>"", "urgency"=>"2", "exec_id"=>"", "type"=>"", "exec_on_tplan"=>"", "executed"=>"", "external_id"=>"4", "z"=>"100", "tc_id"=>"45", "version"=>"1", "tcversion_id"=>"46", "execution_order"=>"40", "user_id"=>"", "feature_id"=>"19", "tcversion_number"=>"", "testsuite_id"=>"44", "active"=>"1"}, "41"=>{"exec_status"=>"p", "status"=>"", "name"=>"testcase3", "assigner_id"=>"", "urgency"=>"2", "exec_id"=>"42", "type"=>"", "exec_on_tplan"=>"43", "executed"=>"42", "external_id"=>"3", "z"=>"100", "tc_id"=>"41", "version"=>"1", "tcversion_id"=>"42", "execution_order"=>"30", "user_id"=>"", "feature_id"=>"18", "tcversion_number"=>"1", "testsuite_id"=>"36", "active"=>"1"}}
|
379
|
+
#
|
380
|
+
def getTestCasesForTestPlan(tpid,tcid=nil,bldid=nil,keyid=nil,executed=nil,assignedto=nil,executestatus=nil)
|
381
|
+
args = {"devKey"=>@devKey,"testplanid"=>tpid}
|
382
|
+
if tcid then
|
383
|
+
args["testcaseid"] = tcid
|
384
|
+
end
|
385
|
+
if bldid then
|
386
|
+
args["buildid"] = bldid
|
387
|
+
end
|
388
|
+
if keyid then
|
389
|
+
args["keywordid"] = keyid
|
390
|
+
end
|
391
|
+
if executed then #boolean
|
392
|
+
args["executed"] = executed
|
393
|
+
end
|
394
|
+
if assignedto then
|
395
|
+
args["assignedto"] = assignedto
|
396
|
+
end
|
397
|
+
if executestatus then #string
|
398
|
+
args["executestatus"] = executestatus
|
399
|
+
end
|
221
400
|
ret = @server.call("tl.getTestCasesForTestPlan",args)
|
222
401
|
end
|
223
402
|
|
403
|
+
|
404
|
+
#
|
405
|
+
#=== �T�v
|
406
|
+
#
|
407
|
+
# getTestCaseIDByName(testcasename,testsuitename)
|
408
|
+
#
|
409
|
+
#=== ����
|
410
|
+
#
|
411
|
+
#+testcasename+::
|
412
|
+
# �e�X�g�P�[�X��
|
413
|
+
#+testsuitename+::
|
414
|
+
# �e�X�g�X�C�[�g��(�I�v�V����)
|
415
|
+
#
|
416
|
+
#=== �߂�l
|
417
|
+
# ��
|
418
|
+
# {"name"=>"testsuite1", "id"=>"36"}
|
419
|
+
#
|
420
|
+
#=== ��O
|
421
|
+
#
|
422
|
+
#=== �ڍ�
|
423
|
+
#
|
424
|
+
# �e�X�g�P�[�X���A�e�X�g�X�C�[�g����n���ƃe�X�g�P�[�XID��Ԃ�
|
425
|
+
# name:�e�X�g�P�[�X��
|
426
|
+
# id:�e�X�g�P�[�XID
|
427
|
+
#
|
428
|
+
#=== ��
|
429
|
+
#
|
430
|
+
# getTestCaseIDByName(tsid) #=>[{"name"=>"testcase1", "id"=>"37"}]
|
431
|
+
#
|
224
432
|
def getTestCaseIDByName(testcasename,testsuitename = nil)
|
225
433
|
args = {"devKey"=>@devKey,"testcasename"=>testcasename}
|
226
434
|
|
@@ -230,31 +438,192 @@ class TestLinkClient
|
|
230
438
|
|
231
439
|
ret = @server.call("tl.getTestCaseIDByName",args)
|
232
440
|
end
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
441
|
+
#
|
442
|
+
#=== �T�v
|
443
|
+
#
|
444
|
+
# createTestCase()
|
445
|
+
#
|
446
|
+
#=== ����
|
447
|
+
#
|
448
|
+
#=== �߂�l
|
449
|
+
#
|
450
|
+
#=== ��O
|
451
|
+
#
|
452
|
+
#=== �ڍ�
|
453
|
+
#
|
454
|
+
# �e�X�g�P�[�X�����쐬����(������)
|
455
|
+
#
|
456
|
+
#=== ��
|
457
|
+
#
|
458
|
+
# createTestCase() #=>
|
459
|
+
#
|
460
|
+
def createTestCase()#������
|
461
|
+
args = {"devKey"=>@devKey}
|
462
|
+
ret = @server.call("tl.createTestCase",args)
|
463
|
+
end
|
464
|
+
#
|
465
|
+
#=== �T�v
|
466
|
+
#
|
467
|
+
# createTestProject()
|
468
|
+
#
|
469
|
+
#=== ����
|
470
|
+
#
|
471
|
+
#=== �߂�l
|
472
|
+
#
|
473
|
+
#=== ��O
|
474
|
+
#
|
475
|
+
#=== �ڍ�
|
476
|
+
#
|
477
|
+
# �e�X�g�v���W�F�N�g���쐬����(������(�����s��))
|
478
|
+
#
|
479
|
+
#=== ��
|
480
|
+
#
|
481
|
+
# createTestProject() #=>
|
482
|
+
#
|
483
|
+
def createTestProject()#�����s��
|
484
|
+
args = {"devKey"=>@devKey}
|
485
|
+
ret = @server.call("tl.createTestProject",args)
|
237
486
|
end
|
487
|
+
#
|
488
|
+
#=== �T�v
|
489
|
+
#
|
490
|
+
# getTestCaseCustomFieldDesignValue()
|
491
|
+
#
|
492
|
+
#=== ����
|
493
|
+
#
|
494
|
+
#=== �߂�l
|
495
|
+
#
|
496
|
+
#=== ��O
|
497
|
+
#
|
498
|
+
#=== �ڍ�
|
499
|
+
#
|
500
|
+
# �J�X�^���t�B�[���h�̒l��(�g�p���@�s��)
|
501
|
+
#
|
502
|
+
#=== ��
|
503
|
+
#
|
504
|
+
# getTestCaseCustomFieldDesignValue() #=>
|
505
|
+
#
|
506
|
+
def getTestCaseCustomFieldDesignValue()
|
507
|
+
args = {"devKey"=>@devKey}
|
508
|
+
ret = @server.call("tl.getTestCaseCustomFieldDesignValue",args)
|
509
|
+
end
|
510
|
+
|
511
|
+
#
|
512
|
+
#=== �T�v
|
513
|
+
#
|
514
|
+
# about()
|
515
|
+
#
|
516
|
+
#=== ����
|
517
|
+
#
|
518
|
+
# �Ȃ�
|
519
|
+
#
|
520
|
+
#=== �߂�l
|
521
|
+
#
|
522
|
+
# "Testlink API Version: 1.0 Beta 3 written by Asiel Brumfield\n contribution by TestLink development Team"
|
523
|
+
#
|
524
|
+
#=== ��O
|
525
|
+
#
|
526
|
+
#=== �ڍ�
|
527
|
+
#
|
528
|
+
# Testlink API�̏�Ԃ�
|
529
|
+
#
|
530
|
+
#=== ��
|
531
|
+
#
|
532
|
+
# about() #=>Testlink API Version: 1.0 Beta 3 written by Asiel Brumfield\n contribution by TestLink development Team
|
533
|
+
#
|
534
|
+
def about
|
535
|
+
ret = @server.call("tl.about")
|
536
|
+
end
|
238
537
|
|
239
|
-
#
|
538
|
+
#
|
539
|
+
#=== �T�v
|
540
|
+
#
|
541
|
+
# sayHello()
|
542
|
+
#
|
543
|
+
#=== ����
|
544
|
+
#
|
545
|
+
# �Ȃ�
|
546
|
+
#
|
547
|
+
#=== �߂�l
|
548
|
+
#
|
549
|
+
# "Hello!"
|
550
|
+
#
|
551
|
+
#=== ��O
|
552
|
+
#
|
553
|
+
#=== �ڍ�
|
554
|
+
#
|
555
|
+
# "Hello!"���Ԃ�
|
556
|
+
# ����m�F�p
|
557
|
+
#
|
558
|
+
#=== ��
|
559
|
+
#
|
560
|
+
# sayHello() #=>"Hello!"
|
561
|
+
#
|
240
562
|
def sayHello
|
241
563
|
ret = @server.call("tl.sayHello")
|
242
564
|
end
|
243
565
|
|
566
|
+
#
|
567
|
+
#=== �T�v
|
568
|
+
#
|
569
|
+
# repeat(message)
|
570
|
+
#
|
571
|
+
#=== ����
|
572
|
+
#
|
573
|
+
#+message+::
|
574
|
+
# ���b�Z�[�W
|
575
|
+
#
|
576
|
+
#=== �߂�l
|
577
|
+
#
|
578
|
+
# "You said: xxxxx"
|
579
|
+
#
|
580
|
+
#=== ��O
|
581
|
+
#
|
582
|
+
#=== �ڍ�
|
583
|
+
#
|
584
|
+
# ���M�������b�Z�[�W��Ԃ�
|
585
|
+
# ����m�F�p
|
586
|
+
#
|
587
|
+
#=== ��
|
588
|
+
#
|
589
|
+
# repeat("message") #=>"You said: message"
|
590
|
+
#
|
244
591
|
#You said: message
|
245
592
|
def repeat(message)
|
246
593
|
args = {"str"=>message}
|
247
594
|
ret = @server.call("tl.repeat",args)
|
248
595
|
end
|
249
596
|
|
250
|
-
# Testlink API Version: 1.0 Beta 3 written by Asiel Brumfield
|
251
|
-
# contribution by TestLink development Team
|
252
|
-
def about
|
253
|
-
ret = @server.call("tl.about")
|
254
|
-
end
|
255
597
|
|
256
598
|
######################################
|
599
|
+
#
|
600
|
+
# �ȉ��Ǝ���
|
601
|
+
#
|
602
|
+
######################################
|
603
|
+
|
604
|
+
|
257
605
|
|
606
|
+
#
|
607
|
+
#=== �T�v
|
608
|
+
#
|
609
|
+
# getProjectID
|
610
|
+
#
|
611
|
+
#=== ����
|
612
|
+
#
|
613
|
+
# �Ȃ�
|
614
|
+
#
|
615
|
+
#=== �߂�l
|
616
|
+
#
|
617
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃe�X�g�v���W�F�N�gID
|
618
|
+
# �� 3
|
619
|
+
#
|
620
|
+
#=== �ڍ�
|
621
|
+
#
|
622
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃe�X�g�v���W�F�N�gID���Ԃ�܂�
|
623
|
+
#
|
624
|
+
#=== ��
|
625
|
+
# getProjectID #=>3
|
626
|
+
#
|
258
627
|
def getProjectID
|
259
628
|
args = {"devKey"=>@devKey}
|
260
629
|
ret = @server.call("tl.getProjects",args)
|
@@ -266,8 +635,30 @@ class TestLinkClient
|
|
266
635
|
raise "ProjectID error"
|
267
636
|
end
|
268
637
|
|
638
|
+
#
|
639
|
+
#=== �T�v
|
640
|
+
#
|
641
|
+
# getTestPlanID(pid)
|
642
|
+
#
|
643
|
+
#=== ����
|
644
|
+
#
|
645
|
+
#+pid+::
|
646
|
+
# �e�X�g�v���W�F�N�gID
|
647
|
+
#
|
648
|
+
#=== �߂�l
|
649
|
+
#
|
650
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃe�X�g�v��ID
|
651
|
+
# �� 3
|
652
|
+
#
|
653
|
+
#=== �ڍ�
|
654
|
+
#
|
655
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃe�X�g�v��ID���Ԃ�܂�
|
656
|
+
#
|
657
|
+
#=== ��
|
658
|
+
# getTestPlanID(3) #=>4
|
659
|
+
#
|
269
660
|
def getTestPlanID(pid)
|
270
|
-
args = {"devKey"=>@devKey,"testprojectid"=>pid}
|
661
|
+
args = {"devKey"=>@devKey,"testprojectid"=>pid}
|
271
662
|
ret = @server.call("tl.getProjectTestPlans",args)
|
272
663
|
ret.each{|tp|
|
273
664
|
tp.each{|id,val|
|
@@ -279,6 +670,28 @@ class TestLinkClient
|
|
279
670
|
raise "TestPlanID error"
|
280
671
|
end
|
281
672
|
|
673
|
+
#
|
674
|
+
#=== �T�v
|
675
|
+
#
|
676
|
+
# getBuildID(tpid)
|
677
|
+
#
|
678
|
+
#=== ����
|
679
|
+
#
|
680
|
+
#+tpid+::
|
681
|
+
# �e�X�g�v��ID
|
682
|
+
#
|
683
|
+
#=== �߂�l
|
684
|
+
#
|
685
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃr���hID
|
686
|
+
# �� 3
|
687
|
+
#
|
688
|
+
#=== �ڍ�
|
689
|
+
#
|
690
|
+
# �ŏ��Ɍ��������A�N�e�B�u�ȃr���hID���Ԃ�܂�
|
691
|
+
#
|
692
|
+
#=== ��
|
693
|
+
# getBuildID(tpid) #=>4
|
694
|
+
#
|
282
695
|
def getBuildID(tpid)
|
283
696
|
args = {"devKey"=>@devKey,"testplanid"=>tpid}
|
284
697
|
ret = @server.call("tl.getBuildsForTestPlan",args)
|
@@ -290,11 +703,32 @@ class TestLinkClient
|
|
290
703
|
raise "BuildID error"
|
291
704
|
end
|
292
705
|
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
706
|
+
#
|
707
|
+
#=== �T�v
|
708
|
+
#
|
709
|
+
# reportTCResultByTCName(testcasename,testsuitename,status)
|
710
|
+
#
|
711
|
+
#=== ����
|
712
|
+
#
|
713
|
+
#+testcasename+::
|
714
|
+
# �e�X�g�P�[�X��
|
715
|
+
#+testsuitename+::
|
716
|
+
# �e�X�g�X�C�[�g��
|
717
|
+
#+status+::
|
718
|
+
# �e�X�g���� p:���� f:���s b:�u���b�N
|
719
|
+
#
|
720
|
+
#=== �߂�l
|
721
|
+
#
|
722
|
+
# �����E���s��Ԃ�
|
723
|
+
# �� [{"message"=>"Success!", "status"=>true, "id"=>"1638"}]
|
724
|
+
#
|
725
|
+
#=== �ڍ�
|
726
|
+
#
|
727
|
+
# �e�X�g�P�[�X���y�уe�X�g�X�C�[�g���Ŏw�肵���e�X�g�P�[�X�Ɏ������ʂ�o�^����
|
728
|
+
#
|
729
|
+
#=== ��
|
730
|
+
# reportTCResultByTCName(testcasename,testsuitename,"p") #=>[{"message"=>"Success!", "status"=>true, "id"=>"1638"}]
|
731
|
+
#
|
298
732
|
def reportTCResultByTCName(testcasename,testsuitename,status)
|
299
733
|
pid = getProjectID
|
300
734
|
tpid = getTestPlanID(pid)
|
@@ -302,7 +736,7 @@ class TestLinkClient
|
|
302
736
|
ret = getTestCaseIDByName(testcasename,testsuitename)
|
303
737
|
tcInfo = ret[0]
|
304
738
|
tcid = tcInfo["id"]
|
305
|
-
ret = reportTCResult(tpid,
|
739
|
+
ret = reportTCResult(tpid,tcid,status,bid)
|
306
740
|
end
|
307
741
|
end
|
308
|
-
|
742
|
+
|