Saturday 2 June, 2007

Getting Test Name from QC

Hi Friends,

Below post is useful to get test name from quality center.

Set td=createobject("TDApiOle80.TDConnection.1")
td.InitConnectionEx "http://qc/qcbin"
td.ConnectProjectEx "DOMAIN", "PROJECT","USERNAME", "PASSWORD"
Set tstMgr = td.TreeManager
Set tsttr = tstMgr.NodeByPath("subject\functionality\SUB FOLDER NAME")
Set tsetFact = tsttr.TestFactory
Set tsetList = tsetFact.NewList("")
For Each tset in tsetList
Msgbox ("Test Name = " & tset.Name)
Next

3 comments:

Swapnadeep (Sunny) said...

To Find a particular the TestSet from QC :

Dim txtTestSet as String
txtTestSet = "TestSet_01"
Dim tset
tdc = New TDAPIOLELib.TDConnection
tdc.InitConnectionEx("http://server/qcbin")
tdc.Login("usrid", "pwd")
tdc.Connect("DOMAIN", "Project")
Dim tstMgr = tdc.TestSetTreeManager
Dim tsttr = tstMgr.NodeByPath("Root\SubFolder")
Dim tsetFact = tsttr.TestSetFactory
Dim tsetList = tsetFact.NewList("")
For Each tset In tsetList
If LCase(Trim(tset.Name)) = LCase(Trim(txtTestSet)) Then
MsgBox("Test Set Found")
End If
Next

jkiran said...

Hi,

How do i get the Complate Path of the Script which is in QC.

For Example, I have script located in "subject\automation\Regression Test Scripts\P1\Service Portability\CHG 6395". I would like to Extract this compleate Path in the xls file.

Can you help me in this.

Thanks and Regards
Kiran

pavan said...

I need complete test case to be exported to Excel from QC using VBA. Can anyone help me in doing that?

Thanks in Advance,
Pavan