cancel
Showing results for 
Search instead for 
Did you mean: 

Is there a way to loop a particular test item in project test items page ?

Contributor

Is there a way to loop a particular test item in project test items page ?

Hi 

 

PFA image loop.png

 

I want to loop the hoghlighted test item present on project test items page for ceratin no of times depaning on value which i recieve from first test item.

 

Can we do it in Test Complete.

4 REPLIES 4
Community Hero

Re: Is there a way to loop a particular test item in project test items page ?

It is possible to run a test item multiple times using Count column, In your case, you want to run n  times based on the last test item result.

 


@rushikesh wrote:

....no of times depaning on value which i recieve from first test item.

How will receive from last test item? Project Variable/ Global Variable?

 

As of now, there is no possibility to run a test item based on any value expect the Count field with help of TestCompete infrastructure.

But this can handle within scripts.


Thanks
Shankar R

LinkedIn | CG-VAK Software | Bitbucket | shankarr.75@gmail.com

“You must expect great things from you, before you can do them”


Extension Available

Contributor

Re: Is there a way to loop a particular test item in project test items page ?

after receiving the value from first test item just try to update the Project.TestItems(TestCase).Count = (value)

Community Hero

Re: Is there a way to loop a particular test item in project test items page ?

@anupamchampati   Project.TestItems(TestCase).Count  is read-only property you can't update at the run time.

refer here: https://support.smartbear.com/testcomplete/docs/reference/project-objects/project/testitem/count.htm...

 


Thanks
Shankar R

LinkedIn | CG-VAK Software | Bitbucket | shankarr.75@gmail.com

“You must expect great things from you, before you can do them”


Extension Available

Community Hero

Re: Is there a way to loop a particular test item in project test items page ?

The answer... is yes... but not based upon the test item.  What you will need to do is build the code that the test item refers to in order to have the loop by dynamic.  As mentioned, the "Count" property of the test item is read-only at runtime so you will need to write a "For" loop in your keyword test or script code to handle this dynamically lengthed loop.


Robert Martin
[Community Expert Group]
Please consider giving a Kudo if I write good stuff
----

Why automate?  I do automated testing because there's only so much a human being can do and remain healthy.  Sleep is a requirement.  So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.

Mysterious Gremlin Master
Extensions available
Ask a SmartBear
Top Kudoed Authors