Forum Discussion

ANW's avatar
ANW
Contributor
13 years ago

How to repeat a task for 1 hour?

We are currently looking into using TestComplete for Load testing our Webpages. I have made a simple task, that opens each of 5 selected pages for a certain number of virtual users.



But it is run only once, and I can't seem to find anywhere, where I can set the number of times it should run the task, or an interval to run in.



F.x. we want to know how many times the five pages can be loaded in an hour. But I can't figure out how to do that, and still get all the test results in the same log??



Any help would be appreciated.

3 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    What I've done is created a test item to link to the LoadTesting Test that was created.  There is a "Count" property then on the TestItem that you can increment.  Part of my process is to run the test with Count = 1 and see how long it takes.  I then calculate from that how many iterations it would take to run for the time desired and input that count in the test item.  Say it takes 2 minutes to run a task.  So, I then calculate that I need to run 30 iterations in order to have the task run repeatedly for an hour.



    See screenshot attached.
  • ANW's avatar
    ANW
    Contributor
    Thanks for the suggestion :)



    Sadly when I did that, then each run of the test resulted in its own log, so it was difficult to get a good overview of the entire test.



    But I have found that LoadComplete will probably be able to do the things we need for this type of testing :)
  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    I found a different way that will give you a better log result.



    http://smartbear.com/support/viewarticle/16817/



    What you would do is do your recorded task and then, instead of setting it up as a test item and setting the count there, you'd add your recorded task to a complex task and set the count there to the number you want.  Then run the Complex Task instead.  that should give you a better view of your overall load for the one test.