Saturday, July 9, 2016

Download UFT(QTP) Scripts from ALM(QC) TestPlan Folder

' Input - QC Folder Path and Local Folder Path
strQCAttachmentsPath = “Subject\Automatin\TestCases”
strDownloadLocation = “C:\QCFiles”

' QC Connection to TestPlan Folder ------ Refer 'ALM Quality Center Connectivity' post
Set treeMgr = gTDConn.TreeManager
Set SubjRoot = treeMgr.NodeByPath(strQCFolderPath)

Set tstFactory = SubjRoot .TestFactory
Set tsetList = tstFactory.NewList("")

'Download all scripts to local folder      
For k=1 to tsetList.Count
 Set TestStorage = tsetList(k).ExtendedStorage
 DwnladFileName = Trim(tsetList(k).Name)
 TestStorage.ClientPath = strDownloadLocation & "\" &  DwnladFileName
 TestDownLoadPath =TestStorage.LoadEx(""TrueNothingFalse)
Next
    ocation & “\” & DwnladFileName

Next

No comments:

Post a Comment