Forum Discussion
omatzura
17 years agoSuper Contributor
Hi,
you can always navigate back "down" the tree with either xXCount/getXXAt/getXXByName methods, for example testSuite.testCaseCount / testSuite.getTestCaseAt( ix ), or XXs[name], for example project.testSuites["TestSuite 1"]
You can get the workspace with project.workspace and then another project with getProjectByName.. A complete example:
testCase.testSuite.project.workspace.getProjectByName( "Project 3" ).testSuites["TestSuite 3"].getTestCaseAt( 2 )
One thing to know is that there is no workspace when running tests using the command-line runners, so project.workspace will return null.
Hope this helps!
regards,
/Ole
eviware.com
you can always navigate back "down" the tree with either xXCount/getXXAt/getXXByName methods, for example testSuite.testCaseCount / testSuite.getTestCaseAt( ix ), or XXs[name], for example project.testSuites["TestSuite 1"]
You can get the workspace with project.workspace and then another project with getProjectByName.. A complete example:
testCase.testSuite.project.workspace.getProjectByName( "Project 3" ).testSuites["TestSuite 3"].getTestCaseAt( 2 )
One thing to know is that there is no workspace when running tests using the command-line runners, so project.workspace will return null.
Hope this helps!
regards,
/Ole
eviware.com