Jyotikrushna_Mo
11 years agoOccasional Visitor
How to Use IntegrationObj.RunTestByName(Project anme,test name)
Hi
I am getting error like "Unable to find the specified element. Project: SmokeTest, TestName:Script|GEO_Admin_IIIE"". I have written the following code:
Sub TC()
Dim TestCompleteObject
Set TestCompleteObject = GetObject(, "TestComplete.TestCompleteApplication")
TestCompleteObject.Visible = "True"
Set IntegrationObj = TestCompleteObject.Integration
IntegrationObj.OpenProjectSuite ("C:\Framework\Test Activity Scripts\SmokeTest\TestComplete\SmokeTest.pjs")
If Not IntegrationObj.IsProjectSuiteOpened Then
MsgBox "The project suite was not opened."
' Closes TestComplete
Else
MsgBox "Project opened"
End If
IntegrationObj.RunTestByName "SmokeTest", "Script|GEO_Admin_IIIe"
End Sub
Here the Project suit Name and location is : C:\Framework\Test Activity Scripts\SmokeTest\TestComplete\SmokeTest.pjs"
Project Name in the above Project Suite is : SmokeTest
My Test presents in the above projects is : Project Name -> Advanced -> Script -> GEO_Admin_IIIe
Could anyone please help me? or can you please an example ?
I am getting error like "Unable to find the specified element. Project: SmokeTest, TestName:Script|GEO_Admin_IIIE"". I have written the following code:
Sub TC()
Dim TestCompleteObject
Set TestCompleteObject = GetObject(, "TestComplete.TestCompleteApplication")
TestCompleteObject.Visible = "True"
Set IntegrationObj = TestCompleteObject.Integration
IntegrationObj.OpenProjectSuite ("C:\Framework\Test Activity Scripts\SmokeTest\TestComplete\SmokeTest.pjs")
If Not IntegrationObj.IsProjectSuiteOpened Then
MsgBox "The project suite was not opened."
' Closes TestComplete
Else
MsgBox "Project opened"
End If
IntegrationObj.RunTestByName "SmokeTest", "Script|GEO_Admin_IIIe"
End Sub
Here the Project suit Name and location is : C:\Framework\Test Activity Scripts\SmokeTest\TestComplete\SmokeTest.pjs"
Project Name in the above Project Suite is : SmokeTest
My Test presents in the above projects is : Project Name -> Advanced -> Script -> GEO_Admin_IIIe
Could anyone please help me? or can you please an example ?